python / cpython

The Python programming language
https://www.python.org
Other
62.63k stars 30.05k forks source link

Document return value of epoll.poll #73433

Open njsmith opened 7 years ago

njsmith commented 7 years ago
BPO 29247
Nosy @njsmith, @berkerpeksag, @marco-buttu, @csabella
PRs
  • python/cpython#4798
  • Files
  • issue29247.diff
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields: ```python assignee = None closed_at = None created_at = labels = ['type-feature', '3.7', 'docs'] title = 'Document return value of epoll.poll' updated_at = user = 'https://github.com/njsmith' ``` bugs.python.org fields: ```python activity = actor = 'berker.peksag' assignee = 'docs@python' closed = False closed_date = None closer = None components = ['Documentation'] creation = creator = 'njs' dependencies = [] files = ['46454'] hgrepos = [] issue_num = 29247 keywords = ['patch'] message_count = 4.0 messages = ['285285', '286482', '286487', '307847'] nosy_count = 6.0 nosy_names = ['njs', 'docs@python', 'berker.peksag', 'marco.buttu', 'Winterflower', 'cheryl.sabella'] pr_nums = ['4798'] priority = 'normal' resolution = None stage = 'patch review' status = 'open' superseder = None type = 'enhancement' url = 'https://bugs.python.org/issue29247' versions = ['Python 3.6', 'Python 3.7'] ```

    njsmith commented 7 years ago

    The documentation for select.epoll.poll doesn't document the return value at all, which is somewhat important information :-)

    I think it's a list of (fd, eventmask) tuples?

    https://docs.python.org/3.7/library/select.html#select.epoll.poll

    berkerpeksag commented 7 years ago

    Thanks for the report, Nathaniel. I agree that the documentation could be improved. Here is a patch. I also moved the constant table to epoll.register() documentation (it's already done in https://docs.python.org/3.7/library/select.html#polling-objects)

    It would be great if you could review the patch, thanks!

    c6a24554-5737-4174-b47e-54fc0403b8dc commented 7 years ago

    The patch LGTM. There is just one typo, I think (see review).

    csabella commented 6 years ago

    Hi Berker,

    Are you interested in making a pull request for this patch? Thanks!