Skip to content

gh-132819: Clarify socket.connect() signal interruption behavior - #155022

Open
Taeknology wants to merge 1 commit into
python:mainfrom
Taeknology:gh-132819
Open

gh-132819: Clarify socket.connect() signal interruption behavior#155022
Taeknology wants to merge 1 commit into
python:mainfrom
Taeknology:gh-132819

Conversation

@Taeknology

@Taeknology Taeknology commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

Clarify how socket.connect() behaves when a connection attempt is
interrupted by a signal. The documentation now separates signal-handler
exceptions, blocking and timeout modes, and non-blocking behavior.

Add Linux-specific tests covering retry after a non-raising signal handler and
propagation when the signal handler raises an exception.

Closes #132819.

Tests

  • ./python -m test test_socket
  • make -C Doc html SPHINXERRORHANDLING=-W

@read-the-docs-community

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #33865759 | 📁 Comparing a3d86c6 against main (afd10f0)

  🔍 Preview build  

1 file changed
± library/socket.html

saitejabandaru-in

This comment was marked as spam.

@Taeknology
Taeknology marked this pull request as ready for review August 1, 2026 13:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting review tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Can the explanation of socket.connect() connection failures be rephrased? I don't think anybody understands what's written.

2 participants