(input: SessionRuntimeInput<'_>)
| 28 | } |
| 29 | |
| 30 | pub(super) fn build_session_runtime(input: SessionRuntimeInput<'_>) -> SessionRuntime { |
| 31 | let (agent_event_tx, _) = broadcast::channel::<AgentEvent>(2048); |
| 32 | |
| 33 | let confirmation_manager = build_confirmation_manager(input.opts, agent_event_tx.clone()); |
| 34 | let command_queue = build_command_queue(input.opts, input.session_id, agent_event_tx.clone()); |
| 35 | let tool_context = build_tool_context( |
| 36 | input.code_config, |
| 37 | input.workspace, |
| 38 | input.opts, |
| 39 | Arc::clone(&input.tool_executor), |
| 40 | agent_event_tx, |
| 41 | ); |
| 42 | |
| 43 | SessionRuntime { |
| 44 | confirmation_manager, |
| 45 | command_queue, |
| 46 | tool_context, |
| 47 | } |
| 48 | } |
| 49 | |
| 50 | fn build_confirmation_manager( |
| 51 | opts: &SessionOptions, |
no test coverage detected