This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author mhchia
Recipients docs@python, mhchia
Date 2019-02-22.09:14:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1550826860.7.0.550984466305.issue36074@roundup.psfhosted.org>
In-reply-to
Content
It seems the result of `asyncio.Server.sockets` after `asyncio.Server.close()` is performed becomes `[]` instead of `None` since python 3.7. However, in the [document 3.7 and 3.8](https://docs.python.org/3.8/library/asyncio-eventloop.html#asyncio.Server.sockets), it states
```
List of socket.socket objects the server is listening on, or None if the server is closed.

Changed in version 3.7: Prior to Python 3.7 Server.sockets used to return an internal list of server sockets directly. In 3.7 a copy of that list is returned.
```
For me, I think the comment `Changed in version 3.7: ...` only emphasizes the "copied list" is returned. IMO it will be more clear if the change from `None` to `[]` is mentioned in the comment as well. Sorry if this issue is not appropriate. Thanks!
History
Date User Action Args
2019-02-22 09:14:20mhchiasetrecipients: + mhchia, docs@python
2019-02-22 09:14:20mhchiasetmessageid: <1550826860.7.0.550984466305.issue36074@roundup.psfhosted.org>
2019-02-22 09:14:20mhchialinkissue36074 messages
2019-02-22 09:14:20mhchiacreate