Repository navigation
Align text and bytes argument and buffer controls - #9698
Draft
youknowdot wants to merge 3 commits into
Draft
youknowdot wants to merge 3 commits into
youknowdot wants to merge 3 commits into
Conversation
Share affix validation and buffer access while preserving translation callbacks, duplicate mappings, and bytes conversion identities. Assisted-by: OpenAI Codex:model version not exposed
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
Use the shared lossless concatenation helper so the qualified-name migration composes without restoring Rust Display formatting. Assisted-by: OpenAI Codex:model version not exposed
This was referenced Nov 4, 2026
Contributor
Merging this PR will not alter performance
Comparing Footnotes
|
Preserve both buffer and bytes-or-string argument imports while integrating the upstream hex separator conversion. Assisted-by: OpenAI Codex:model version not exposed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Group related CPython 3.15 text/bytes controls in 357 substantive changed lines (+200/-157):
Four production Rust files only. No Python, Lib, test, expected-failure marker or workflow changes. Partition/rpartition remain unchanged: pinned CPython intentionally retains the supplied separator object.
Reference and validation
Compared with CPython commit d220409a13b77de7a6c30abe16ea90db01528edc: bytes implementation, bytes helpers, and Unicode implementation.
50,330 bounded CPython/source-model assertions and 12,028 independent assertions passed. Coverage includes Unicode/surrogate bounds, tuple item validation, repeated mappings, bytes/bytearray consumers, exact/subclass identities and PEP 688 buffer acquisition/release callbacks with mutation and error paths. These are reference/model checks, not Rust implementation execution.
Independent exact-source review passed, including the final two lazy-default Clippy corrections. Bytearray #9694 composition passed git apply --check. Final focused host-env/VM/stdlib threading cargo check, normal all-targets Clippy and ordinary commit hooks passed. Clippy emitted exactly four unchanged main-baseline diagnostics: one POSIX needless-collect and three ElementTree lints. Strict -D warnings remains blocked by that baseline; no warnings were suppressed.
Native RustPython execution was not performed because the required execution guard has not been verified. Full workspace/C-API suites and cross-platform runtime validation remain unrun. Hosted CI is required; no expected failure is claimed resolved without runtime evidence.
Remaining limits
The existing qualified-type-name formatter does not preserve surrogate-containing type metadata. Generic binder diagnostics and pre-existing bytearray translation/export behavior outside these shared changes remain unchanged. Older architecture/GC/fallible-allocation PRs overlap some files and may need later textual reconciliation; no duplicate behavior fix was found in the 210-PR overlap audit.
AI-assisted contribution by OpenAI Codex, disclosed in the commit trailer.
Shared type-name compatibility
The bytes constructor diagnostic uses the existing WTF-8 concatenation helper so it remains lossless when composed with #9700. Other text/bytes control-flow changes are byte-identical to the previously reviewed head. Independent in-memory composition review verified the exact previous head plus this narrow formatting change. Final focused host-env/VM/stdlib threading check, normal all-targets Clippy and ordinary hooks passed; the same four unchanged baseline diagnostics remain. No new runtime execution or test changes are claimed.