Repository navigation
Isolate GC ownership test from child automatic collection - #9196
Conversation
Disable automatic GC before creating the child cycle so the test measures only whether the parent forced collection can reach child-owned objects. Keep both assertions and the parent collection retry unchanged. Assisted-by: OpenAI Codex:model version unavailable
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
📒 Files selected for processing: 1
✨ 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 |
Merging this PR will not alter performance
Comparing Footnotes
|
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
Disable automatic GC in the child interpreter before constructing the cycle in
collections_only_reach_the_collecting_interpreter.This test verifies that a forced collection in the parent does not collect objects owned by the child. The child's automatic collector can otherwise collect its own unreachable cycle before the first
live_nodesassertion. Disable that independent collection path while keeping bothlive_nodes == 2assertions, the cycle itself, and the parent's forced-collection retry unchanged.The source supports this explanation for the intermittent pre-collection assertion failure reported during #9185. That original failure has not been independently reproduced here.
Validation
cargo test --workspace --exclude rustpython_wasm --exclude rustpython-venvlauncher --exclude rustpython-capi: passed (1,400 passed, 18 existing ignored across tests and doctests).(cd crates/capi && cargo test): 123 passed, 4 existing ignored.cargo clippy --workspace --all-targets --exclude rustpython_wasm --exclude rustpython-venvlauncher --exclude rustpython-capi -- -D warnings: passed.(cd crates/capi && cargo clippy --all-targets -- -D warnings): passed.git diff --check: passed.Validated using Rust 1.99.1. An initial link attempt lacked the libffi development library; retry and all gates above passed after adding official Debian libffi 3.4.8-2 locally.
AI assistance: OpenAI Codex (model version unavailable).