Skip to content

fix(sdk): lock registerToolSessionTransitionCleanup out of public inventory - #3837

Merged
Yeachan-Heo merged 1 commit into
Yeachan-Heo:devfrom
innocarpe:fix/issue-3813-sdk-seam-register-tool-cleanup
Aug 5, 2026
Merged

fix(sdk): lock registerToolSessionTransitionCleanup out of public inventory#3837
Yeachan-Heo merged 1 commit into
Yeachan-Heo:devfrom
innocarpe:fix/issue-3813-sdk-seam-register-tool-cleanup

Conversation

@innocarpe

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #3813. Current dev fails SDK operation inventory > accepts the committed generated matrix with:

Pending review source seam: agent_session:registerToolSessionTransitionCleanup

AgentSession.registerToolSessionTransitionCleanup is an internal tool/session lifecycle registration seam used for shared artifact-manager ownership across transitions. It is not a user-facing SDK control (same class as registerToolSessionCleanup, already locked out).

Changes

  • Add agent_session:registerToolSessionTransitionCleanup to LOCKED_EXCLUSIONS in generate-sdk-operation-inventory.ts.
  • Regenerate operation-inventory.generated.json.

Why this matters

Any exact-head PR based on current dev that runs coding-agent shard inventory checks inherits this red, including notification PR #3834 (whose own generation guard and package check are green). Owner review of #3834 classified this as a pre-existing base regression that still must be green on the exact head before merge.

Test plan

  • bun test packages/coding-agent/test/sdk-operation-inventory.test.ts — 17 pass
  • bun packages/coding-agent/scripts/generate-sdk-operation-inventory.ts --check
  • Full Dev CI coding-agent shards (expected green after this lands)

Scope

  • Refs #3813 only — inventory classification, not a behavior change.

…entory

Yeachan-Heo#3813 added AgentSession.registerToolSessionTransitionCleanup for shared
artifact-manager ownership on session transitions. The method is an internal
lifecycle registration seam, parallel to registerToolSessionCleanup, but was
never added to LOCKED_EXCLUSIONS. Exact-head Dev CI then fails the generated
SDK operation inventory check on any PR based on current dev.

Classify the seam as a locked exclusion and regenerate the committed matrix.

Lore-id: 3813seam01
Constraint: do not expose as a public SDK control
Rejected: map to a new SDK operation | no user-facing control exists
Confidence: high
Scope-risk: narrow
Reversibility: easy
Tested: sdk-operation-inventory.test.ts (17 pass); inventory --check
Not-tested: full coding-agent shard matrix on CI

Refs Yeachan-Heo#3813

@Yeachan-Heo Yeachan-Heo left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Red-team read-only review: SDK inventory exclusion seam

Head SHA verified: db9ad498763ffa6ffbba5573bc431cab246b559f

Scope

2 files, +13 lines:

  • generate-sdk-operation-inventory.ts — adds agent_session:registerToolSessionTransitionCleanup to LOCKED_EXCLUSIONS
  • operation-inventory.generated.json — regenerated committed matrix

Validation performed

1. Locked exclusion is internal — ✅
registerToolSessionTransitionCleanup (agent-session.ts:3413-3418) is a #private-backed lifecycle registration that adds a cleanup callback to this.#toolSessionTransitionCleanups. It has no SDK adapter mapping, no user-facing control surface, and is parallel to the already-excluded registerToolSessionCleanup (line 3407, excluded at generator line 38). The rationale string accurately describes its purpose: "internal tool transition cleanup registration for shared artifact-manager ownership."

2. Generator output matches committed JSON — ✅

bun scripts/generate-sdk-operation-inventory.ts --check → exit 0
bun test test/sdk-operation-inventory.test.ts → 17 pass, 0 fail

The --check mode confirmed the committed operation-inventory.generated.json is byte-identical to what the generator produces from the updated LOCKED_EXCLUSIONS. No drift.

3. CI status — ✅
14 SUCCESS, 6 SKIPPED, 0 FAILURE. Mergeable.

Verdict

Clean mechanical exclusion of an internal lifecycle seam introduced by #3813. The generator and committed matrix are in sync. No public SDK surface is exposed or removed.

Approved.

— gaebal-gajae

@Yeachan-Heo
Yeachan-Heo merged commit c6e1c3c into Yeachan-Heo:dev Aug 5, 2026
20 checks passed
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.

2 participants