Skip to content

Commit c991873

Browse files
committed
docs: Indent "Returns:" properly
Then "Returns:" uses more than one line, it should be indented one level more to mark the continuation of one return specification, as it is possible to have multiple return specifications. Signed-off-by: Leandro Lucarella <[email protected]>
1 parent ce4d0e6 commit c991873

File tree

5 files changed

+11
-11
lines changed

5 files changed

+11
-11
lines changed

src/frequenz/channels/anycast.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,8 @@ async def send(self, msg: T) -> bool:
134134
msg: The message to be sent.
135135
136136
Returns:
137-
Boolean indicating whether the message was sent, based on whether
138-
the channel is open or not.
137+
Whether the message was sent, based on whether the channel is open
138+
or not.
139139
"""
140140
if self._chan.closed:
141141
return False

src/frequenz/channels/base_classes.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ async def send(self, msg: T) -> bool:
2424
2525
Returns:
2626
Whether the message was sent, based on whether the channel is open
27-
or not.
27+
or not.
2828
"""
2929

3030

@@ -103,8 +103,8 @@ def peek(self) -> Optional[T]:
103103
"""Return the latest value that was sent to the channel.
104104
105105
Returns:
106-
The latest value received by the channel, and None, if nothing has
107-
been sent to the channel yet.
106+
The latest value received by the channel, and `None`, if nothing
107+
has been sent to the channel yet.
108108
"""
109109

110110

src/frequenz/channels/broadcast.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ def peek(self) -> Optional[T]:
320320
"""Return the latest value that was sent to the channel.
321321
322322
Returns:
323-
The latest value received by the channel, and None, if nothing has
324-
been sent to the channel yet, or if the channel is closed.
323+
The latest value received by the channel, and `None`, if nothing
324+
has been sent to the channel yet, or if the channel is closed.
325325
"""
326326
return self._chan._latest # pylint: disable=protected-access

src/frequenz/channels/merge.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ async def receive(self) -> Optional[T]:
4848
"""Wait until there's a message in any of the channels.
4949
5050
Returns:
51-
The next message that was received, or None, if all channels have
52-
closed.
51+
The next message that was received, or `None`, if all channels have
52+
closed.
5353
"""
5454
# we use a while loop to continue to wait for new data, in case the
5555
# previous `wait` completed because a channel was closed.

src/frequenz/channels/merge_named.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ async def receive(self) -> Optional[Tuple[str, T]]:
3535
"""Wait until there's a message in any of the channels.
3636
3737
Returns:
38-
The next message that was received, or None, if all channels have
39-
closed.
38+
The next message that was received, or `None`, if all channels have
39+
closed.
4040
"""
4141
# we use a while loop to continue to wait for new data, in case the
4242
# previous `wait` completed because a channel was closed.

0 commit comments

Comments
 (0)