René's URL Explorer Experiment


Title: Align socket and socketserver with Python 3.15 final by youknowdot · Pull Request #9156 · RustPython/RustPython · GitHub

Open Graph Title: Align socket and socketserver with Python 3.15 final by youknowdot · Pull Request #9156 · RustPython/RustPython

X Title: Align socket and socketserver with Python 3.15 final by youknowdot · Pull Request #9156 · RustPython/RustPython

Description: Summary Split the socket/socketserver portion of #8954 into five files, synchronized with CPython 3.15 final (d220409a13b77de7a6c30abe16ea90db01528edc). Import the complete socket.py, socketserver.py, test_socket.py, and test_socketserver.py using the actual scripts/update_lib copy/migrate commands. Preserve all five existing AF_ALG expected-failure markers. No hand-edited library/test bodies, duplicate snippets, support-module changes, or workflows. Match setsockopt positional parsing, index-before-buffer conversion, and error ordering. Python conversions, warnings, and buffer acquisition finish before the socket lock; the socket guard drops before the buffer export is released. Correct final-CPython optlen semantics beyond the original mega patch: use the index protocol, mask to unsigned 32 bits, and issue DeprecationWarning("integer value out of range") outside [-2**31, 2**32 - 1]. Warning-as-error propagates before the third-argument shape check or host call. Reject Windows buffer lengths above INT_MAX before the host call. Preserve arbitrary-precision integer ports in getaddrinfo, accept index objects before string/bytes handling, and return an empty canonical name when the resolver supplies none. Provenance and overlap The three Python files other than test_socket.py match the pinned CPython blobs byte-for-byte. test_socket.py differs only by the five retained AF_ALG decorators. The tested commit is retained rather than rebased over unrelated main changes. At publication, the main-relative PR patch still contains exactly the reviewed five files. #9143 remains open and adds an expected-failure marker to test_getaddrinfo_int_port_overflow; that marker must be preserved if integrated because this run did not execute the real _testcapi-dependent body. The older socket overlap in #8007 concerns separate SSL/wait gating. Local validation Normal commit hooks, the matching narrow release build, and strict stdlib/VM all-targets Clippy passed: cargo build --release --offline --locked -p rustpython --bin rustpython -j1 \ --no-default-features --features threading,stdlib,stdio,importlib,host_env cargo clippy --release --offline --locked -p rustpython-stdlib -p rustpython-vm \ --all-targets --no-default-features \ --features rustpython-stdlib/compiler,rustpython-stdlib/host_env,rustpython-stdlib/threading,rustpython-vm/compiler,rustpython-vm/gc,rustpython-vm/host_env,rustpython-vm/stdio,rustpython-vm/importlib,rustpython-vm/encodings,rustpython-vm/threading \ -- -D warnings Eight unchanged canonical method extracts passed, each in a fresh bounded process: test_socket.GeneralModuleTests: testDefaultTimeout, testGetSockOpt, testSetSockOpt, test_setsockopt_errors, test_SocketType_is_socketobject, and testNewAttributes test_socketserver.TestModule.test_deprecated__version__ test_socketserver.MiscTestCase.test_all Four temporary supplemental checks passed: numeric-only getaddrinfo index/type/boundary/canonical-name cases; setsockopt optlen warnings and error order; a tiny native AF_UNIX socketpair/sendfile check; and socketserver attributes without starting a server. Every giant-optlen check supplied a non-None third argument and was rejected before host access. The sendfile fixture was 32 bytes, with 50 bytes transferred across the bounded cases; no external DNS was used. The additional canonical test_getaddrinfo_int_port_overflow naturally skipped because the real _testcapi module is absent. Its body remains untested; no fake module or constants were substituted. The runtime used the original library inventory with source/module-origin checks and time, memory, output, descriptor, and process limits. Initial missing native-math/IDNA admission failures were preserved, then corrected only in separately reviewed temporary import allowlists. No repository behavior or test assertion was changed to clear those gates. Source hashes remained unchanged across build, Clippy, and runtime, and an independent review checked the selected result receipts. This is bounded Linux coverage, not a full test_socket/test_socketserver or workspace-suite pass. Windows/macOS/BSD/WASI behavior, broad DNS/non-UTF8/SSL/AF_VSOCK parity, raw-device tests, and server/fork loops were not exercised. The Windows length guard was source-reviewed only. Validation identities: Commit: ed08422bea7d1483a9a5a615870b7339a5dcc76b Five-file patch SHA-256: e4493b63070d4578a60c1893273c5f791108a34d76781827730604d17b7c9624 Tested binary SHA-256: d44bdf898535141ef097c856552d332f1478443f69f14e515dc7307e1d288316 Result manifest SHA-256: 9f31d781770839feaebe550240542bf4ac7d5f4f3d7e09f54c58b6977e0bf36d AI assistance OpenAI Codex assisted with the implementation, canonical-source synchronization, source review, bounded validation, and this description. The exact model version was unavailable; the commit includes an Assisted-by trailer.

Open Graph Description: Summary Split the socket/socketserver portion of #8954 into five files, synchronized with CPython 3.15 final (d220409a13b77de7a6c30abe16ea90db01528edc). Import the complete socket.py, socketserver...

X Description: Summary Split the socket/socketserver portion of #8954 into five files, synchronized with CPython 3.15 final (d220409a13b77de7a6c30abe16ea90db01528edc). Import the complete socket.py, socketserver...

Opengraph URL: https://github.com/RustPython/RustPython/pull/9156

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:43b77fdc-19bf-bb27-7c19-fa41bbb600be
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idD318:1C94F:2B8A4DA:37CF351:6B01F929
html-safe-nonce6b21ef39173b9ac74a0cfbb99844c5c485c7664d17c5879c2b06afb5371a0236
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMzE4OjFDOTRGOjJCOEE0REE6MzdDRjM1MTo2QjAxRjkyOSIsInZpc2l0b3JfaWQiOiIxNDUwNzc5MzkxMDUwMjUwNTM3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac1a7f0718e721d014bea297b539ea1f5e47716e7e9a6a7765aec6e75f3a7c695b
hovercard-subject-tagpull_request:4874572743
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/RustPython/RustPython/pull/9156/files
twitter:imagehttps://avatars.githubusercontent.com/u/336763669?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/336763669?s=400&v=4
og:image:altSummary Split the socket/socketserver portion of #8954 into five files, synchronized with CPython 3.15 final (d220409a13b77de7a6c30abe16ea90db01528edc). Import the complete socket.py, socketserver...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/RustPython/RustPython git https://github.com/RustPython/RustPython.git
octolytics-dimension-user_id39710557
octolytics-dimension-user_loginRustPython
octolytics-dimension-repository_id135201145
octolytics-dimension-repository_nwoRustPython/RustPython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id135201145
octolytics-dimension-repository_network_root_nwoRustPython/RustPython
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release423dbb54c5e7bfecc838eb387c1435eb3d0e760d
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/RustPython/RustPython/pull/9156/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FRustPython%2FRustPython%2Fpull%2F9156%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FRustPython%2FRustPython%2Fpull%2F9156%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=RustPython%2FRustPython
Reloadhttps://github.com/RustPython/RustPython/pull/9156/files
Reloadhttps://github.com/RustPython/RustPython/pull/9156/files
Reloadhttps://github.com/RustPython/RustPython/pull/9156/files
RustPythonhttps://github.com/RustPython
RustPythonhttps://github.com/RustPython/RustPython
Codehttps://github.com/RustPython/RustPython
Issues195 (195)https://github.com/RustPython/RustPython/issues
Pull requests133 (133)https://github.com/RustPython/RustPython/pulls
Discussionshttps://github.com/RustPython/RustPython/discussions
Actionshttps://github.com/RustPython/RustPython/actions
Projectshttps://github.com/RustPython/RustPython/projects
Wikihttps://github.com/RustPython/RustPython/wiki
Security and qualityhttps://github.com/RustPython/RustPython/security
Insightshttps://github.com/RustPython/RustPython/insights
Sign up for GitHub https://github.com/signup?return_to=%2FRustPython%2FRustPython%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FRustPython%2FRustPython%2Fissues%2Fnew%2Fchoose
youknowonehttps://github.com/youknowone
RustPython:mainhttps://github.com/RustPython/RustPython/tree/main
youknowdot:split/socket-315-finalhttps://github.com/youknowdot/RustPython/tree/split/socket-315-final
Conversation 5 https://github.com/RustPython/RustPython/pull/9156
Commits 1 https://github.com/RustPython/RustPython/pull/9156/commits
Checks 30 https://github.com/RustPython/RustPython/pull/9156/checks
Files changed https://github.com/RustPython/RustPython/pull/9156/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
Align socket and socketserver with Python 3.15 final https://github.com/RustPython/RustPython/pull/9156/files#top
Show all changes 1 commit https://github.com/RustPython/RustPython/pull/9156/files
ed08422 Align socket and socketserver with Python 3.15 youknowdot Oct 15, 2026 https://github.com/RustPython/RustPython/pull/9156/commits/ed08422bea7d1483a9a5a615870b7339a5dcc76b
Clear filters https://github.com/RustPython/RustPython/pull/9156/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
socket.py https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
socketserver.py https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
test_socket.py https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
test_socketserver.py https://github.com/RustPython/RustPython/pull/9156/files#diff-79409c9a249cddde00120586b439d625ac8de0361eb75e842ef4406be5488895
socket.rs https://github.com/RustPython/RustPython/pull/9156/files#diff-184374c26b267e900965c88a05d2c963f9c2fcdc8419201b0fa39b9ed462b5c7
Lib/socket.pyhttps://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
View file https://github.com/youknowdot/RustPython/blob/ed08422bea7d1483a9a5a615870b7339a5dcc76b/Lib/socket.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9156/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
https://github.com/RustPython/RustPython/pull/9156/files#diff-081d33d48e9390350bb1ef860c52de799d1647b58e33b07173ae2549532cbfbe
Lib/socketserver.pyhttps://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
View file https://github.com/youknowdot/RustPython/blob/ed08422bea7d1483a9a5a615870b7339a5dcc76b/Lib/socketserver.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9156/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
https://github.com/RustPython/RustPython/pull/9156/files#diff-c00d56a0c132ee4bdf79f55a4b43643cf314df1fe122c07c539e120c7ec98b5e
Lib/test/test_socket.pyhttps://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
View file https://github.com/youknowdot/RustPython/blob/ed08422bea7d1483a9a5a615870b7339a5dcc76b/Lib/test/test_socket.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9156/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
chatgpt-codex-connectorhttps://github.com/apps/chatgpt-codex-connector
Oct 16, 2026https://github.com/RustPython/RustPython/pull/9156/files#r4289931051
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
https://camo.githubusercontent.com/a08bbb8a949f7033433a88444eeae385ff6a5e599d92f878fb05fa85707b7816/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f50312d6f72616e67653f7374796c653d666c6174
AGENTS.md:L278-L282https://github.com/RustPython/RustPython/blob/ed08422bea7d1483a9a5a615870b7339a5dcc76b/AGENTS.md#L278-L282
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
https://github.com/RustPython/RustPython/pull/9156/files#diff-ce79808e12f7a252c1747c23ba11810d4dc22ce0af4b9419bac647ad3a2a8389
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9156/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.