Skip to content

core: stop emitting legacy command events directly - #31629

Merged
owenlin0 merged 2 commits into
mainfrom
owen/ca-675-emit-unified-exec-interactions-as-canonical-commandexecution
Jul 8, 2026
Merged

core: stop emitting legacy command events directly#31629
owenlin0 merged 2 commits into
mainfrom
owen/ca-675-emit-unified-exec-interactions-as-canonical-commandexecution

Conversation

@owenlin0

@owenlin0 owenlin0 commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Description

This PR removes the last path in core that emits ExecCommandBegin / ExecCommandEnd directly.

Every command execution now starts and completes through canonical ItemStarted / ItemCompleted(TurnItem::CommandExecution). The existing HasLegacyEvent compatibility layer still fans out Begin/End afterward, so raw core event consumers and legacy rollout replay keep seeing the same events.

UnifiedExecInteraction is dormant today. Live unified exec uses UnifiedExecStartup for command lifecycle and TerminalInteraction for write_stdin and polling, so this is code cleanup rather than a current product behavior change. The main win is the code-level invariant where all core flows emit TurnItem instead of legacy events.

What changed

  • Removed the UnifiedExecInteraction branches that emitted legacy command events directly.
  • Routed every command source through the existing canonical CommandExecution lifecycle and compatibility fanout.

@owenlin0
owenlin0 force-pushed the owen/ca-675-emit-unified-exec-interactions-as-canonical-commandexecution branch from 9d2f94b to ea68460 Compare July 8, 2026 19:39
@owenlin0 owenlin0 changed the title core: emit canonical unified exec interaction items refactor(core): remove dormant unified exec interaction carveout Jul 8, 2026
@owenlin0 owenlin0 changed the title refactor(core): remove dormant unified exec interaction carveout core: stop authoring legacy command events directly Jul 8, 2026
@owenlin0 owenlin0 changed the title core: stop authoring legacy command events directly core: stop emitting legacy command events directly Jul 8, 2026
@owenlin0
owenlin0 marked this pull request as ready for review July 8, 2026 19:47
@owenlin0
owenlin0 requested a review from a team as a code owner July 8, 2026 19:47
process_id: Option<&str>,
) {
let (session, turn, rx_event) =
make_session_and_context_with_dynamic_tools_and_rx(Vec::new()).await;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

is this a good test? can we do an integration one instead (if we need one at all)?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

ack, let me look

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

removed the test, we've got existing tests that cover this

@owenlin0
owenlin0 enabled auto-merge (squash) July 8, 2026 20:42
@owenlin0
owenlin0 merged commit 602dbb4 into main Jul 8, 2026
35 checks passed
@owenlin0
owenlin0 deleted the owen/ca-675-emit-unified-exec-interactions-as-canonical-commandexecution branch July 8, 2026 20:53
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants