Skip to content

chore: collapse literal Object.freeze pyramids into deepFreeze - #238

Merged
ScriptedAlchemy merged 1 commit into
mainfrom
chore/freeze-consolidation
Sep 1, 2026
Merged

chore: collapse literal Object.freeze pyramids into deepFreeze#238
ScriptedAlchemy merged 1 commit into
mainfrom
chore/freeze-consolidation

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Summary

  • Collapse nested Object.freeze stacks on fresh literals to the existing deepFreeze helper (packages/agent-bundle/src/core/freeze.ts) plus a Workbench-local copy (packages/workbench/src/freeze.ts). Public API stays plain objects; Effect immutables stay internal.
  • Leave single shallow freezes and any freeze that shares a mutable reference (detached snapshot / capability-table callers). Do not weaken those contracts.
  • Skip active-lane files: src/install/, src/host-contracts/, create-agent-bundle, .github/workflows, and Workbench document-stage / runtime-model surfaces.

Test plan

  • Unit pool for agent-bundle, rsc-runtime, workbench (2265 passed)
  • Frozen-semantics parity: capability tables, agent-document, state kernel, detached runtime snapshots (83 passed)
  • pnpm typecheck
  • pnpm lint
  • CI green, then merge

No changeset: internal readability refactor, no public behavior change.

@changeset-bot

changeset-bot Bot commented Sep 1, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: fa70c9b

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-01T23:38:27.336843Z 9c04cb6 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@pkg-pr-new

pkg-pr-new Bot commented Sep 1, 2026

Copy link
Copy Markdown
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle@238
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/create-agent-bundle@238
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/@agent-bundle/runtime@238

commit: fa70c9b

Nested freeze stacks on fresh object literals were readability noise.
Shared-reference snapshots stay shallow-frozen so detach semantics do not change.
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