Skip to content
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

socket.getblocking() documentation lists opposite equivalence #104882

Closed
chrisaycock opened this issue May 24, 2023 · 1 comment
Closed

socket.getblocking() documentation lists opposite equivalence #104882

chrisaycock opened this issue May 24, 2023 · 1 comment
Labels
docs Documentation in the Doc dir

Comments

@chrisaycock
Copy link

chrisaycock commented May 24, 2023

Documentation

The documentation for socket.getblocking() states:

This is equivalent to checking socket.gettimeout() == 0.

But that's the opposite of what it means. According to the source code, getblocking() returns False if and only if gettimeout() returns 0.0.

Linked PRs

@chrisaycock chrisaycock added the docs Documentation in the Doc dir label May 24, 2023
AlexWaygood pushed a commit that referenced this issue Jun 4, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Jun 4, 2023
…t.getblocking()` and `socket.gettimeout()` (pythonGH-105026)

(cherry picked from commit 5a5ed7a)

Co-authored-by: Joe Geisbauer <joegeisbauer@gmail.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Jun 4, 2023
…t.getblocking()` and `socket.gettimeout()` (pythonGH-105026)

(cherry picked from commit 5a5ed7a)

Co-authored-by: Joe Geisbauer <joegeisbauer@gmail.com>
AlexWaygood pushed a commit that referenced this issue Jun 4, 2023
…et.getblocking()` and `socket.gettimeout()` (GH-105026) (#105283)

gh-104882: Docs: fix description of relationship between `socket.getblocking()` and `socket.gettimeout()` (GH-105026)
(cherry picked from commit 5a5ed7a)

Co-authored-by: Joe Geisbauer <joegeisbauer@gmail.com>
AlexWaygood pushed a commit that referenced this issue Jun 4, 2023
…et.getblocking()` and `socket.gettimeout()` (GH-105026) (#105284)

gh-104882: Docs: fix description of relationship between `socket.getblocking()` and `socket.gettimeout()` (GH-105026)
(cherry picked from commit 5a5ed7a)

Co-authored-by: Joe Geisbauer <joegeisbauer@gmail.com>
@AlexWaygood
Copy link
Member

Fixed, and backported to 3.12 and 3.11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir
Projects
None yet
Development

No branches or pull requests

2 participants