René's URL Explorer Experiment


Title: Reuse checked signatures for deque, timezone and type by youknowdot · Pull Request #9773 · RustPython/RustPython · GitHub

Open Graph Title: Reuse checked signatures for deque, timezone and type by youknowdot · Pull Request #9773 · RustPython/RustPython

X Title: Reuse checked signatures for deque, timezone and type by youknowdot · Pull Request #9773 · RustPython/RustPython

Description: Consolidated into #9756 At the user's request, all commits and tests from this PR are now included unchanged in #9756 at the same combined head f51d264b2228321f444a10ddc4d97e9ac42826b0. This PR is closed only to keep one active PR; its review discussion and original commits are preserved. The description below records this PR's implementation and validation before consolidation. Summary This is a dependent follow-up to #9756. Current head f51d264b2228321f444a10ddc4d97e9ac42826b0 is stacked on the actual #9756 head e30a3bddbc79044cadabe36c378aa038a2c99c1c, with #9758's receiver changes already in the underlying main. The two follow-up commits distinguish declared omitted defaults from unknown defaults and reuse checked argument signatures for class metadata. Keep production documentation bodies in the existing rustpython-doc database. No copied Rust docstrings or implicit docstring-header bypass remains. Reuse #9756's shared FromArgs::TEXT_SIGNATURE for initializer/constructor class metadata instead of adding another class-only override mechanism. Class signatures have no receiver marker; method/classmethod markers are checked by the common macro-time validation. Remove the old implicit-receiver counting workarounds. Python argument metadata no longer includes the receiver after #9758. Distinguish a declared omitted default (DefaultRepr::Unrepresentable) from an unknown default (DefaultRepr::Unknown). This lets timezone obtain (offset, name=) through ordinary signature generation, without a timezone override. Unknown defaults and unnamed leaf metadata remain rejected by the class representability check. Extend checked overrides to CPython's deque bracket notation without /. Apply explicit overrides only to deque, deque.index, and type.__prepare__. Preserve the existing declared metadata contract for known unrestricted raw argument binders such as type.__prepare__; unknown binding metadata remains rejected. Actual argument conversion and dispatch are unchanged. Add metadata/parser regression coverage and signature/doc/inspect checks, including type.__prepare__ ignoring arbitrary arguments and returning a fresh namespace. CPython 3.15 basis _collectionsmodule.c: deque constructor and index explicitly use Argument Clinic @text_signature overrides. _datetimemodule.c: datetime.timezone.__new__ is Clinic-generated with name: unicode = NULL, displayed as . typeobject.c: type_prepare ignores its arguments; its manually declared method header publishes $cls, name, bases, /, **kwds. Validation Verified on 2026-11-17: Current head's hosted checks: 16 successful, 3 skipped, none failed or pending. Successful checks include Linux/macOS/Windows snippet and CPython tests, Rust tests on all three platforms, Ubuntu Clippy, Miri, WASM package/demo, WASI tests, cargo doc, lint, cargo shear, and CodSpeed. The skipped checks are the draft parity workflow and two conditional matrix placeholders; skipped checks are not claimed as passes. Local derive tests on the implementation before the dependency-only rebases: 41 passed. The dependency rebases retained the changes, with the final conflict resolved by keeping both the upstream map_or_else lint correction and this PR's validator selection. Normal configured pre-commit checks and the CPython 3.15.2 builtin_signature.py snippet passed again after the latest rebase. Local full-workspace validation was interrupted for shared build-resource scheduling and is not claimed complete for this revision. The hosted results above are for the exact current head, not an earlier revision. AI assistance OpenAI Codex assisted with review, implementation, and validation.

Open Graph Description: Consolidated into #9756 At the user's request, all commits and tests from this PR are now included unchanged in #9756 at the same combined head f51d264b2228321f444a10ddc4d97e9ac42826b0. This PR...

X Description: Consolidated into #9756 At the user's request, all commits and tests from this PR are now included unchanged in #9756 at the same combined head f51d264b2228321f444a10ddc4d97e9ac42826b0. Thi...

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

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:577d7395-27b4-acc4-070a-0adc7fb2cea4
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idD32A:1F68:AE44FB:EC478D:6B01E40F
html-safe-noncec256d808ab20fa8080a128acd84dc801d18d43ad92cf4784082465e70e5ded7c
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMzJBOjFGNjg6QUU0NEZCOkVDNDc4RDo2QjAxRTQwRiIsInZpc2l0b3JfaWQiOiI0NjEyODk5NDY0NDQ3OTEwOTI3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacbbcc2094602b1415632042f6364ddbe2ae3099e0f9752ea1675fa7efd58fc4e3
hovercard-subject-tagpull_request:5229831218
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/9773/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:altConsolidated into #9756 At the user's request, all commits and tests from this PR are now included unchanged in #9756 at the same combined head f51d264b2228321f444a10ddc4d97e9ac42826b0. This PR...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
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
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/RustPython/RustPython/pull/9773/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FRustPython%2FRustPython%2Fpull%2F9773%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%2F9773%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/9773/files
Reloadhttps://github.com/RustPython/RustPython/pull/9773/files
Reloadhttps://github.com/RustPython/RustPython/pull/9773/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
youknowdothttps://github.com/youknowdot
RustPython:mainhttps://github.com/RustPython/RustPython/tree/main
youknowdot:fix/legacy-native-signatures-20261110https://github.com/youknowdot/RustPython/tree/fix/legacy-native-signatures-20261110
Conversation 3 https://github.com/RustPython/RustPython/pull/9773
Commits 5 https://github.com/RustPython/RustPython/pull/9773/commits
Checks 37 https://github.com/RustPython/RustPython/pull/9773/checks
Files changed https://github.com/RustPython/RustPython/pull/9773/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9773/files
Reuse checked signatures for deque, timezone and type https://github.com/RustPython/RustPython/pull/9773/files#top
Show all changes 5 commits https://github.com/RustPython/RustPython/pull/9773/files
ababd01 Add checked text-signature overrides shared by argument specs youknowdot Nov 16, 2026 https://github.com/RustPython/RustPython/pull/9773/commits/ababd017069b79ba630c4f5d171d181c5bd204fd
ce60891 Separate shared signature docs from field options codex Nov 16, 2026 https://github.com/RustPython/RustPython/pull/9773/commits/ce608918405e1d92de4865d400ad628bcab16503
e30a3bd Use a direct fallback for optional signature tokens codex Nov 16, 2026 https://github.com/RustPython/RustPython/pull/9773/commits/e30a3bddbc79044cadabe36c378aa038a2c99c1c
c41d89f Distinguish declared omitted defaults from unknown defaults codex Nov 16, 2026 https://github.com/RustPython/RustPython/pull/9773/commits/c41d89f16812053adcb67ef7a8505a502d4eead1
f51d264 Reuse checked argument signatures for class metadata codex Nov 16, 2026 https://github.com/RustPython/RustPython/pull/9773/commits/f51d264b2228321f444a10ddc4d97e9ac42826b0
Clear filters https://github.com/RustPython/RustPython/pull/9773/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9773/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9773/files
from_args.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
lib.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-1b272457e12e3b4142bf16f49a3fdc9bae11316a2ca8e676d3b7ba452aebce20
pyclass.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
pymodule.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-bd1b19a26ea802742bdb1006a08982fb26404140e1dd0b5162271a6646258d39
text_signature.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-e67542df06a437c18043e1f934e81203fd1473023a657c38441d2ae267b70e12
util.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-bc2426df61f173d5880449913c159a85524e8969df4743433c59436e77c3321d
lib.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-20d9586a7e5e7a1ffb491abaefbd0c7a0c23bbea9524c66d06c8cc65c00ad539
csv.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-acf098d7e921238a0873aca66fb246b2f9e424ac9fac0419462c7cbad68c95a8
anystr.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-dd35a1000e2e6c0e7e4310bf9339045337d1db8ef9795c3cd7f2dbbb8f3dd809
bytearray.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-bd8962db12555ddc9945c543b57069611c9b3f24f133fbf3a76c7c60fe1cfddd
bytes.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-6b402f3feb41119eef6e230cb7efe615c9804a4ed5ce25dc9121ed85ed495343
str.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-a04ea1f7734fe40189e756196e034e6dedfcd5c82f2925e58cfd51ba7432073a
type.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-fb88962f9343ca7b8d31bfe34f5063136575e05eadae6fccb3b64658e14b0d6c
bytes_inner.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-94a4e578864d9ec94d59e2b7f57ea8f5a67aa734d28847c8921202237f2156b7
argument.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-e9ca87fa93dba19813dc8ace2b1f9cbfd3cb9f29560b80c1e38963101107cfff
mod.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-c2fa22f10e57d8883fb9de7511a7345f799c1c3e87cda5ac557e3d513020d950
signature.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-d8d33ac439d83ede8760de2d14f5bc298f336c809ffeeaece6be77fe6fd5865c
_collections.rs https://github.com/RustPython/RustPython/pull/9773/files#diff-b843141b8e6f6469647984c0bf98eb863ed1da2b30f3f77e0803edba966c1249
builtin_signature.py https://github.com/RustPython/RustPython/pull/9773/files#diff-10345555e7703ee171a268bc4c9e034fe6c4065467dd03018f308e7cdc29361b
stdlib_csv.py https://github.com/RustPython/RustPython/pull/9773/files#diff-3d834bd9b008124d1d115c12c5a34a5b18603e108f9ea2ea03f9d506bd9161bd
crates/derive-impl/src/from_args.rshttps://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
View file https://github.com/youknowdot/RustPython/blob/f51d264b2228321f444a10ddc4d97e9ac42826b0/crates/derive-impl/src/from_args.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9773/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
https://github.com/RustPython/RustPython/pull/9773/files#diff-90c094cca198d94b0145e4a485172fba68de5c77f49fcd05a6b882896721f1c9
crates/derive-impl/src/lib.rshttps://github.com/RustPython/RustPython/pull/9773/files#diff-1b272457e12e3b4142bf16f49a3fdc9bae11316a2ca8e676d3b7ba452aebce20
View file https://github.com/youknowdot/RustPython/blob/f51d264b2228321f444a10ddc4d97e9ac42826b0/crates/derive-impl/src/lib.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9773/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9773/files#diff-1b272457e12e3b4142bf16f49a3fdc9bae11316a2ca8e676d3b7ba452aebce20
https://github.com/RustPython/RustPython/pull/9773/files#diff-1b272457e12e3b4142bf16f49a3fdc9bae11316a2ca8e676d3b7ba452aebce20
crates/derive-impl/src/pyclass.rshttps://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
View file https://github.com/youknowdot/RustPython/blob/f51d264b2228321f444a10ddc4d97e9ac42826b0/crates/derive-impl/src/pyclass.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/RustPython/RustPython/pull/9773/{{ revealButtonHref }}
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
https://github.com/RustPython/RustPython/pull/9773/files#diff-26c99b2025ccb53d8e726042a48a5886526d898281c27735bd1b6ebd51e55feb
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9773/files
Please reload this pagehttps://github.com/RustPython/RustPython/pull/9773/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.