fix(runtime): expose module namespace data descriptors - #9899
fix(runtime): expose module namespace data descriptors#9899proggeramlug wants to merge 1 commit into
Conversation
22ff043 to
8b004bb
Compare
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 8 included reviews per hour; 5 remain after this review. 📝 WalkthroughWalkthroughThe runtime now synthesizes standard data descriptors for module namespace properties while preserving live binding values. The dynamic import alias test validates descriptor flags, accessor absence, and values before and after reassignment. ChangesModule namespace descriptors
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to Module namespace exports now report standard data descriptors while retaining current live-binding values. The change is covered for alias reassignment and descriptor shape, with no current merge-blocking risk identified. Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 75.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 3 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
|
Landed on |
Module namespace live exports are stored as accessors so their values track reassignment, which made
Object.getOwnPropertyDescriptor(ns, key)expose the internal getter instead of the data descriptor required for namespace exotic objects. Namespace own-property reflection now reads the current export through the rooted live-binding path and returns{ value, writable: true, enumerable: true, configurable: false }for both live and snapshot exports.The dynamic-import alias fixture now checks descriptor shape and value before and after reassignment, including its existing forced moving-GC configuration.
Validation:
cargo test -p perry-runtime --profile perry-dev -- --test-threads=1: 3,237 passed, 4 ignored; doc tests greenscripts/run_lint_gates.sh: all 64 gates passed, 2 CI-only checks skipped locallyFixes #9889
Summary by CodeRabbit