Title: Snapshot live code through its owner in the compiler adapter by youknowdot · Pull Request #9450 · RustPython/RustPython · GitHub
Open Graph Title: Snapshot live code through its owner in the compiler adapter by youknowdot · Pull Request #9450 · RustPython/RustPython
X Title: Snapshot live code through its owner in the compiler adapter by youknowdot · Pull Request #9450 · RustPython/RustPython
Description: Summary Address the design review by removing the immutable construction-provenance/layout framework, external-bytecode rejection policy, and frozen-decoding rewiring. Merge main as of preparation (a20e9cdc284f70be0877dd41a8373f8d935479f3) without rewriting the original PR history. The replacement is limited to _testinternalcapi's existing compiler adapter: Snapshot live code through the owning PyCode's cached public bytecode and existing monitoring-wrapper resolution, constructing fresh execution storage without specialization caches. Retain owners while recursively converting nested code constants; release each monitoring lock before visiting nested constants. Preserve current filenames through the owner getter, and retain the adapter's existing BasicBag metadata conversion contract. CPython basis and scope CPython reconstructs and caches public bytecode using owner monitoring metadata to resolve wrappers. Its constructor validation does not introduce the removed provenance policy. This is not a general live-code clone API or a claim of malformed-bytecode safety/concurrency equivalence. The existing adapter reconstructs constants rather than preserving identities as CPython's PyList_AsTuple does. Unsupported arbitrary co_consts, existing BorrowedConstant container leaks, and surrogate-bearing metadata limitations remain outside this change. No lossy string normalization is introduced. The earlier monitoring dependency claim should not be read as validated by this narrowed change. Validation Guarded cargo check -p rustpython-vm --lib and strict Clippy (-D warnings) passed with compiler,codegen,threading,host_env,stdio,doc,importlib, locked/offline and defaults disabled. Both phases verified exact unchanged source/tool manifests, fresh VM artifacts, and terminated process groups. Normal commit hooks passed. The first hook attempt made one layout-only Rust formatting change; exact replacement/non-whitespace-byte equivalence against the checked source was verified, and every other validated source file remained identical. Native checks were not rerun after that formatting-only change. Runtime, C-API, Python tests, and full workspace tests were not run; no CLI binary was built. This is focused static validation only. AI assistance OpenAI Codex assisted with source research, implementation, review-response drafting, and guarded static validation. Commit messages include an Assisted-by trailer. Human runtime verification is not claimed.
Open Graph Description: Summary Address the design review by removing the immutable construction-provenance/layout framework, external-bytecode rejection policy, and frozen-decoding rewiring. Merge main as of preparation ...
X Description: Summary Address the design review by removing the immutable construction-provenance/layout framework, external-bytecode rejection policy, and frozen-decoding rewiring. Merge main as of preparation ...
Opengraph URL: https://github.com/RustPython/RustPython/pull/9450
X: @github
Domain: github.com
| react-profiling | 0 |
| react-import-map | react,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-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:2b789ba6-253a-22c4-ee07-6123377e81bc |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 8472:4BB79:3826A4C:47BB29A:6B01FE84 |
| html-safe-nonce | fe7a2bc20dc2e1101efc5ea635703c071373cfaafb6d8eefe23c3d9b3bdb8948 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NDcyOjRCQjc5OjM4MjZBNEM6NDdCQjI5QTo2QjAxRkU4NCIsInZpc2l0b3JfaWQiOiIxMjg0Mzg4MjIxOTQ5NzA1ODYwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | d729ace9daf25c0e744acee1c9ffb29a3ac36b58cb5e72a368b279729212dd89 |
| hovercard-subject-tag | pull_request:5060600532 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/RustPython/RustPython/pull/9450/files |
| twitter:image | https://avatars.githubusercontent.com/u/336763669?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/336763669?s=400&v=4 |
| og:image:alt | Summary Address the design review by removing the immutable construction-provenance/layout framework, external-bytecode rejection policy, and frozen-decoding rewiring. Merge main as of preparation ... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/RustPython/RustPython git https://github.com/RustPython/RustPython.git |
| octolytics-dimension-user_id | 39710557 |
| octolytics-dimension-user_login | RustPython |
| octolytics-dimension-repository_id | 135201145 |
| octolytics-dimension-repository_nwo | RustPython/RustPython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 135201145 |
| octolytics-dimension-repository_network_root_nwo | RustPython/RustPython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width