René's URL Explorer Experiment


Title: Match CPython length hint diagnostics and cleanup order by youknowdot · Pull Request #10017 · RustPython/RustPython · GitHub

Open Graph Title: Match CPython length hint diagnostics and cleanup order by youknowdot · Pull Request #10017 · RustPython/RustPython

X Title: Match CPython length hint diagnostics and cleanup order by youknowdot · Pull Request #10017 · RustPython/RustPython

Description: Summary Match CPython 3.15's length-hint diagnostics for non-integer, negative, and overflowing hints, including the fully qualified type names. Preserve the distinction between an error while binding a descriptor and a TypeError raised by the hint itself. Match CPython's object release order as well: release the temporary callable before inspecting its result, and release a valid negative integer result before reading the receiver's name for the exception. Reuse the same signed-size conversion for operator.length_hint's explicit default, keeping the signature and default unchanged. References: CPython's length-hint implementation and Argument Clinic default conversion. Validation Rust 1.100 locked Linux build, strict scoped VM Clippy, and the repository's applicable pinned hooks passed. Two new focused regressions pass with this change and CPython 3.15.2; both fail on the previous RustPython. The two existing targeted native and pure-Python operator tests pass. Exact output matches CPython for the targeted direct calls and list/bytes consumers, including the public operator signature. No expectedFailure markers changed. Other platforms and performance were not verified locally. Codex assisted with the implementation and verification. Human review is pending.

Open Graph Description: Summary Match CPython 3.15's length-hint diagnostics for non-integer, negative, and overflowing hints, including the fully qualified type names. Preserve the distinction between an error while ...

X Description: Summary Match CPython 3.15's length-hint diagnostics for non-integer, negative, and overflowing hints, including the fully qualified type names. Preserve the distinction between an error wh...

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

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.114.3

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:f9674655-4fc3-12bc-f499-4a4d811622db
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idD124:3B6B85:A30EDC:D326BE:6B0635AA
html-safe-nonce594c1ff8a3e4013041386018120525198008d6d66e4c55bfcdcaf7ce258f2848
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMTI0OjNCNkI4NTpBMzBFREM6RDMyNkJFOjZCMDYzNUFBIiwidmlzaXRvcl9pZCI6IjQwNDgwOTc5MTYyNjU4Mzc5OTUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac62bb23d979f47284523aff203661ab0975cc71ccd725b03fa3a696494883873c
hovercard-subject-tagpull_request:5477573814
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/10017/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 Match CPython 3.15's length-hint diagnostics for non-integer, negative, and overflowing hints, including the fully qualified type names. Preserve the distinction between an error while ...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonec3584c853cd39700ecff6e2cf8364295ffdb5313e571046c41cd2479270f7df0
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
release9eb3bb1597d09170a5f282cd38ae376dee1a5ec1
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/RustPython/RustPython/pull/10017/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FRustPython%2FRustPython%2Fpull%2F10017%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%2F10017%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/10017/files
Reloadhttps://github.com/RustPython/RustPython/pull/10017/files
Reloadhttps://github.com/RustPython/RustPython/pull/10017/files
RustPythonhttps://github.com/RustPython
RustPythonhttps://github.com/RustPython/RustPython
Codehttps://github.com/RustPython/RustPython
Issues197 (197)https://github.com/RustPython/RustPython/issues
Pull requests130 (130)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:fix/length-hint-cpython-diagnosticshttps://github.com/youknowdot/RustPython/tree/fix/length-hint-cpython-diagnostics
Conversation 2 https://github.com/RustPython/RustPython/pull/10017
Commits 1 https://github.com/RustPython/RustPython/pull/10017/commits
Checks 19 https://github.com/RustPython/RustPython/pull/10017/checks
Files changed 5 https://github.com/RustPython/RustPython/pull/10017/files
Match CPython length hint diagnostics and cleanup order https://github.com/RustPython/RustPython/pull/10017/files#top
Show all changes 1 commit https://github.com/RustPython/RustPython/pull/10017/files
b43dafa Match CPython length hint diagnostics and cleanup order youknowdot Nov 24, 2026 https://github.com/RustPython/RustPython/pull/10017/commits/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e
Clear filters https://github.com/RustPython/RustPython/pull/10017/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/10017/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/10017/files
int.rs https://github.com/RustPython/RustPython/pull/10017/files#diff-6f6fb35904d4bdd7481e9d90622e7fc41a1eff225053e762f724150581464887
number.rs https://github.com/RustPython/RustPython/pull/10017/files#diff-4b6c8f777cc85a356e8cfd03078d3119eeecaa76f326aac365e67c91c724a8ae
_operator.rs https://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
vm_ops.rs https://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
stdlib_operator.py https://github.com/RustPython/RustPython/pull/10017/files#diff-b6ce46164c9fcf05efa8524f4ba2de33b4a253393d2369f8d123b089e1985197
crates/vm/src/builtins/int.rshttps://github.com/RustPython/RustPython/pull/10017/files#diff-6f6fb35904d4bdd7481e9d90622e7fc41a1eff225053e762f724150581464887
View file https://github.com/youknowdot/RustPython/blob/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e/crates/vm/src/builtins/int.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/10017/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/10017/files#diff-6f6fb35904d4bdd7481e9d90622e7fc41a1eff225053e762f724150581464887
https://github.com/RustPython/RustPython/pull/10017/files#diff-6f6fb35904d4bdd7481e9d90622e7fc41a1eff225053e762f724150581464887
crates/vm/src/function/number.rshttps://github.com/RustPython/RustPython/pull/10017/files#diff-4b6c8f777cc85a356e8cfd03078d3119eeecaa76f326aac365e67c91c724a8ae
View file https://github.com/youknowdot/RustPython/blob/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e/crates/vm/src/function/number.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/10017/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/10017/files#diff-4b6c8f777cc85a356e8cfd03078d3119eeecaa76f326aac365e67c91c724a8ae
https://github.com/RustPython/RustPython/pull/10017/files#diff-4b6c8f777cc85a356e8cfd03078d3119eeecaa76f326aac365e67c91c724a8ae
crates/vm/src/stdlib/_operator.rshttps://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
View file https://github.com/youknowdot/RustPython/blob/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e/crates/vm/src/stdlib/_operator.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/10017/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
https://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
https://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
https://github.com/RustPython/RustPython/pull/10017/files#diff-6dcca900ef9d987bbb3d2f28088c1689508a112ee3dda7ab8706f2d329ea41b3
crates/vm/src/vm/vm_ops.rshttps://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
View file https://github.com/youknowdot/RustPython/blob/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e/crates/vm/src/vm/vm_ops.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/10017/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
https://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
https://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
https://github.com/RustPython/RustPython/pull/10017/files#diff-7f5fecda3e3100247b725e8eba74b99604553656485b9b160cddd0a863e77c1e
extra_tests/snippets/stdlib_operator.pyhttps://github.com/RustPython/RustPython/pull/10017/files#diff-b6ce46164c9fcf05efa8524f4ba2de33b4a253393d2369f8d123b089e1985197
View file https://github.com/youknowdot/RustPython/blob/b43dafa7177cbc5a0f5ab9a8e9023a9dced8561e/extra_tests/snippets/stdlib_operator.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/10017/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/10017/files#diff-b6ce46164c9fcf05efa8524f4ba2de33b4a253393d2369f8d123b089e1985197
https://github.com/RustPython/RustPython/pull/10017/files#diff-b6ce46164c9fcf05efa8524f4ba2de33b4a253393d2369f8d123b089e1985197
Please reload this pagehttps://github.com/RustPython/RustPython/pull/10017/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

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.