Repository navigation
Align XML backend and canonical libraries with Python 3.15 - #9197
Conversation
|
Caution Review failedThe pull request is closed. Finishing Touches
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. Comment |
📦 Library DependenciesThe following Lib/ modules were modified. Here are their dependencies: [x] lib: cpython/Lib/xml dependencies:
dependent tests: (38 tests)
Legend:
|
Merging this PR will not alter performance
Comparing Footnotes
|
There was a problem hiding this comment.
no, vendoring is strictly not allowed. tell me why this is required
Retain the existing XML backend accounting changes and their explicit registry publication limitation. Preserve canonical XML tests and existing RustPython guards, including multiline marker explanations through update_lib. Assisted-by: OpenAI Codex:model version unavailable
Assisted-by: OpenAI Codex:model version unavailable
Replace the vendored crate sources with the published xml 1.4.0 archive and reapply the amplification accounting patch on top of it. The two lexer hunks that conflicted with the new line-ending normalization are merged into the 1.4.0 read loop. The patch no longer normalizes CR in entity values or collapses CRLF in attribute values, because the 1.4.0 lexer and attribute reader already do so. Update the checksums, recorded upstream commit, archive hash and provenance notes, and require version 1.4 for the path dependency. Assisted-by: Claude Code:claude-opus-5-5
ef40541 to
1576b65
Compare
Merge pinned main 75df7a8 into the existing XML branch and replace the vendored implementation with the reviewed 14-file compatibility split. Keep registry xml 1.4.0 and its existing expansion limits; exclude the unsupported cumulative-amplification APIs and updater-tool changes. Migrate canonical CPython 3.15 XML files through update_lib and retire 24 proven stale expected-failure decorators without changing assertions. Fresh locked/offline build and targeted stdlib Clippy passed. The exact 52 bounded canonical observations produced 49 successes and 3 retained expected failures; this is not a full XML-suite or cross-platform claim. The first guarded build timed out; a reviewed same-source continuation completed successfully without treating the timed-out attempt as a pass. Skip cspell only for this one correction commit under the user's explicit exception. All other applicable normal hooks remain enabled. AI assistance covered extraction, migration, source review and bounded validation. The actual model identifier is not exposed. Assisted-by: dot: model version not exposed
Linux and macOS canonical CI both demonstrate that the existing unsupported-scheme resolver test passes. Retire only its expected-failure decorator through update_lib, preserving its canonical assertions. This does not implement external DTD parsing. AI assistance: dot diagnosed CI, migrated the marker, and reviewed the source delta and normal-hook validation; the model version is not exposed. Assisted-by: dot: model version not exposed
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Summary
Replace the earlier vendored implementation with an independent, non-vendored XML compatibility split from #8954.
xml1.4.0 dependency and its existing expansion limits. No Cargo changes, vendored files or updater-tool changes remain in this PR's diff.d220409a13b77de7a6c30abe16ea90db01528edc, using the existingscripts/update_libtool.The previous custom backend supplied cumulative amplification-accounting APIs absent from the published crate. This replacement excludes those APIs instead of vendoring the backend. Its pre-existing fixed expansion protections are unchanged.
Fresh validation
The local validation below was run on replacement commit
dcff68be451106be0de358b266152b424c837edaagainst pinned main75df7a8c2e47f981163792fe0154d698c28bcf93. The subsequent one-decorator follow-up is described separately below:--no-default-features --features stdlib,stdio,importlib,host_env,threading: passed.rustpython-stdliblibrary Clippy with-D warnings: passed.The 52 local observations are not a complete XML-suite or workspace validation. On replacement commit
dcff68be, Linux, macOS and Windows canonical CI found one stale expected-failure marker:ExpatReaderTest.test_expat_external_dtd_enabledpassed unexpectedly in each initial run and rerun. This follow-up removes that decorator throughupdate_lib, leaving assertions unchanged. The test validates external resolver dispatch and the expected unsupported-schemeURLError, not successful external DTD parsing. Correctness CI fordcff68behas finished: all other jobs passed; native canonical jobs failed only on this stale marker. On follow-up commit4eb7a6889f08c93c6b459f7daeba7bae82364aac, all three native canonical jobs and the other 20 correctness jobs passed; Lib Dependencies also passed. The remaining Linux Rust job reached its 45-minute execution limit during sandbox-mode compilation and was cancelled, so full CI is not green. A targeted rerun request using the PR author account was denied because repository admin rights are required; a maintainer rerun is needed. Earlier broad results in this PR applied to the superseded vendored implementation, not this replacement.Remaining limitations
NotImplementedError.Commit hooks
cspell alone was skipped for the initial XML correction commit under explicit user authorization. The normal Git commit ran conflict checking, Ruff format/check, redundant-test-patches and rustfmt successfully. Prettier reported no applicable files under normal merge-hook selection. The separate exception for #9342 was not reused; no broader hook waiver applies.
For the one-line Python-only follow-up, the normal Git commit ran with
SKIPunset: conflict checking, Ruff format/check and redundant-test-patches passed. Rustfmt, cspell and Prettier naturally reported no applicable files. No further hook exception was used.AI assistance: dot assisted with extraction, canonical migration, source review and bounded validation. The exact model version is not exposed.