Skip to content

fix(core): enforce step settlement ordering - #35281

Closed
kitlangton wants to merge 1 commit into
execution-errorsfrom
event-closeout
Closed

kitlangton wants to merge 1 commit into
execution-errorsfrom
event-closeout

Conversation

@kitlangton

Copy link
Copy Markdown
Contributor

Closes #35020.

Summary

Closes the remaining V2 event-audit cleanup after the fragment and execution/error lanes.

  • Enforces tool settlement before the owning step terminal event across clean, provider-error, thrown-LLM-error, content-filter, hosted-tool, interruption, and defect paths.
  • Emits exactly one session.step.ended or session.step.failed per step.
  • Adds assistant-scoped exact-order regression tests for local and hosted tools.
  • Documents the cross-drain orphan settlement exception and step-scoped callID uniqueness.
  • Rewrites compaction checkpoint headings around continuation/resumption semantics.
  • Removes generated legacy SDK duplicate names only after normalized shape-equivalence checks.
  • Fails loudly if SessionNext-style generated noise reappears.

Checkpoint Vocabulary

## Continuation Goal
## Operating Constraints
## Progress
### Completed
### In Flight
### Blocked
## Decisions To Preserve
## Resume From Here
## Context To Preserve
## Working Files

Verification

  • 170 runner-adjacent Core tests passed after rebasing onto feat(core): add execution lifecycle and structured errors #35280
  • SDK typecheck and test passed
  • Full-repo pre-push typecheck passed
  • Legacy SDK generation reproduced identically on consecutive runs
  • No Shell1V2, numbered SessionStructuredError, or SessionNext duplicate noise remains
  • Prettier clean; file-scoped oxlint has 0 errors
  • Independent settlement-order and SDK-safety reviews passed after coverage/equivalence hardening

No schema migration is required for this behavior/template/codegen cleanup.

Post-Merge

After the stack lands, close #35020 and #35021 with shipped/deferred mappings, then remove the temporary event-audit coordination plan in a final closeout change.

@kitlangton

Copy link
Copy Markdown
Contributor Author

Collapsed into #35272 so the Session event contract lands in one PR with one V2 history reset.

@kitlangton kitlangton closed this Jul 4, 2026
@kitlangton
kitlangton deleted the event-closeout branch July 4, 2026 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant