Skip to content

fix(perry): register PERRY_OBJECT_LITERAL_SHAPE_METHODS as a build-cache input - #9144

Merged
proggeramlug merged 1 commit into
mainfrom
fix/9122-register-literal-shape-knob
Aug 30, 2026
Merged

fix(perry): register PERRY_OBJECT_LITERAL_SHAPE_METHODS as a build-cache input#9144
proggeramlug merged 1 commit into
mainfrom
fix/9122-register-literal-shape-knob

Conversation

@proggeramlug

@proggeramlug proggeramlug commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

codegen_env_vars_are_build_cache_inputs is red on main.

#9122 introduced PERRY_OBJECT_LITERAL_SHAPE_METHODS (a codegen kill switch) without registering it in BUILD_CACHE_ENV_VARS. I caught that during review and prepared the registration, but it did not make it into the commit that merged — my cherry-pick of the fix resolved against the wrong branch and silently no-op'd, so I merged #9122 without it. My mistake, not the PR author's.

these codegen env vars key neither the build cache nor an exclusion (#6394's rule):
["PERRY_OBJECT_LITERAL_SHAPE_METHODS"]

The knob selects between two different literal-birth emission sequences, so it is a genuine cache key rather than an exclusion candidate — a cached object built with it on must not serve a build with it off.

Verified on this branch: the gate test passes (1 passed), fmt clean.

Summary by CodeRabbit

  • Bug Fixes
    • Prevented incompatible cached object results from being reused when object methods capture this.
    • Ensured build cache behavior remains consistent across different object-literal compilation settings.

…che input

#9122 introduced the knob; its registration was prepared but did not make
it into the merged commit, leaving codegen_env_vars_are_build_cache_inputs
red on main. The knob selects between two literal-birth emission
sequences, so it is a cache key.
@proggeramlug
proggeramlug merged commit 166d3ea into main Aug 30, 2026
16 of 20 checks passed
@proggeramlug
proggeramlug deleted the fix/9122-register-literal-shape-knob branch August 30, 2026 08:04
@coderabbitai

coderabbitai Bot commented Aug 30, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: d2b98068-117a-49d9-82f9-3cfeeed47f43

📥 Commits

Reviewing files that changed from the base of the PR and between 4994c77 and d203b40.

📒 Files selected for processing (1)
  • crates/perry/src/commands/compile/build_cache.rs

📝 Walkthrough

Walkthrough

The build cache now includes PERRY_OBJECT_LITERAL_SHAPE_METHODS as an environment input, preventing cache reuse across different object literal shape method settings.

Changes

Build cache invalidation

Layer / File(s) Summary
Track object literal shape methods setting
crates/perry/src/commands/compile/build_cache.rs
Adds PERRY_OBJECT_LITERAL_SHAPE_METHODS to BUILD_CACHE_ENV_VARS.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: jdalton

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/9122-register-literal-shape-knob

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant