Skip to content

refactor(core): simplify runner transitions#33270

Closed
kitlangton wants to merge 4 commits into
devfrom
simplify/v2-runner-transitions
Closed

refactor(core): simplify runner transitions#33270
kitlangton wants to merge 4 commits into
devfrom
simplify/v2-runner-transitions

Conversation

@kitlangton

@kitlangton kitlangton commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

Summary

  • model expected Session turn retries as Data.TaggedEnum state and results instead of defects
  • replace mutually recursive retry functions with one iterative, exhaustive transition loop
  • represent overflow-recovery availability as state so exhausted recovery cannot retain pending promotion
  • expose concurrent agent mismatch as a typed tagged error and handle it with catchTag

Verification

  • bun run --cwd packages/core test test/session-runner.test.ts test/session-runner-recorded.test.ts test/session-compaction.test.ts test/session-prompt.test.ts test/session-runner-message.test.ts (117 passed)
  • bun run --cwd packages/core typecheck
  • pre-push bun turbo typecheck (23 tasks passed)
  • simplify review plus four Effect-smol idiom/algebra reviews against the local Effect v4 source

@kitlangton kitlangton closed this Jun 22, 2026
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