(commits: StreamCommit[], patch?: FooterPatch, nextSubagent?: FooterSubagentState)
| 502 | } |
| 503 | |
| 504 | const syncFooter = (commits: StreamCommit[], patch?: FooterPatch, nextSubagent?: FooterSubagentState) => { |
| 505 | const current = pickView(state.data, state.subagent, state.blockers) |
| 506 | const footer = composeFooter({ |
| 507 | patch, |
| 508 | subagent: nextSubagent, |
| 509 | current, |
| 510 | previous: state.footerView, |
| 511 | }) |
| 512 | |
| 513 | if (commits.length === 0 && !footer) { |
| 514 | state.footerView = current |
| 515 | return |
| 516 | } |
| 517 | |
| 518 | input.trace?.write("reduce.output", { |
| 519 | commits, |
| 520 | footer: traceFooterOutput(footer), |
| 521 | }) |
| 522 | writeSessionOutput( |
| 523 | { |
| 524 | footer: input.footer, |
| 525 | trace: input.trace, |
| 526 | }, |
| 527 | { |
| 528 | commits, |
| 529 | footer, |
| 530 | }, |
| 531 | ) |
| 532 | state.footerView = current |
| 533 | } |
| 534 | |
| 535 | const resolveShellAgent = Effect.fn("RunStreamTransport.resolveShellAgent")(function* ( |
| 536 | agent: string | undefined, |
no test coverage detected