-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
gh-71566: Fix SocketType introduction in the socket documentation. #93288
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Most changes to Python require a NEWS entry. Please add it using the blurb_it web app or the blurb command-line tool. |
You don't need NEWS, please delete it. A |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two wording suggestions.
A
Doc/library/socket.rst
Outdated
This is the base class for a type object of socket objects, and | ||
``isinstance(socket(...), SocketType)`` returns ``True``. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the base class for a type object of socket objects, and | |
``isinstance(socket(...), SocketType)`` returns ``True``. | |
This is the base class for socket objects, such that | |
``isinstance(socket(...), SocketType)`` is ``True``. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your professional advice. As we can see, socket.SocketType
is the base class for the type object socket.socket
. Consider that elsewhere in this document socket object
refers to an instance of the type object socket.socket
. Wouldn't it be less precise if we just said that SocketType
is the base class of socket objects
? Looking forward to your more suggestions.
Doc/library/socket.rst
Outdated
``isinstance(socket(...), SocketType)`` returns ``True``. | ||
|
||
.. versionchanged:: 3.0 | ||
SocketType is now the base class for the socket object type. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SocketType is now the base class for the socket object type. | |
SocketType is the base class for socket objects | |
rather than being ``type(socket(...))``` directly. |
In the previous commit, SocketType was changed to the base class for the socket object type.
The purpose of this PR is to align the documentation with the above modifications.