docs: add missing docstrings for public API#3404
Open
nightcityblade wants to merge 1 commit intopython-trio:mainfrom
Open
docs: add missing docstrings for public API#3404nightcityblade wants to merge 1 commit intopython-trio:mainfrom
nightcityblade wants to merge 1 commit intopython-trio:mainfrom
Conversation
Add docstrings to: - MemorySendChannel class - MemoryReceiveChannel class - MemoryChannelStatistics class and attributes - SocketStream.send_all, wait_send_all_might_not_block, send_eof, receive_some, aclose - HasFileno.fileno - ParkingLot.broken_by attribute Fixes python-trio#3221
Member
|
See discussion in #3388 |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3404 +/- ##
===============================================
Coverage 100.00000% 100.00000%
===============================================
Files 128 128
Lines 19424 19425 +1
Branches 1318 1318
===============================================
+ Hits 19424 19425 +1
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #3221
Adds docstrings to the following public API items that were showing up without documentation:
MemorySendChannel— class docstring referencingopen_memory_channelMemoryReceiveChannel— class docstring referencingopen_memory_channelMemoryChannelStatistics— class docstring with attribute descriptionsSocketStream.send_all,wait_send_all_might_not_block,send_eof,receive_some,aclose— short docstrings referencing the parent ABC methodsHasFileno.fileno— method docstringParkingLot.broken_by— attribute docstringThe SocketStream method docstrings use
See :meth:...cross-references rather than duplicating the ABC documentation, keeping them in sync with the parent class.Tests run:
pytest src/trio/_tests/test_channel.py src/trio/_tests/test_highlevel_socket.py src/trio/_core/_tests/test_parking_lot.py— all pass.