Skip to content

Commit d94800a

Browse files
committed
fixes
1 parent f4ac403 commit d94800a

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

crates/agent/src/agent/util/request_channel.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,3 @@ where
101101
let (tx, rx) = mpsc::channel(16);
102102
(RequestSender::new(tx), rx)
103103
}
104-

crates/agent/src/cli/run.rs

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,6 @@
11
use std::io::Write as _;
22
use std::process::ExitCode;
33

4-
use clap::Args;
5-
use eyre::{
6-
Result,
7-
bail,
8-
};
9-
use serde::{
10-
Deserialize,
11-
Serialize,
12-
};
13-
use tokio::io::AsyncWriteExt;
14-
use tracing::warn;
15-
164
use agent::agent::Agent;
175
use agent::agent::agent_config::load_agents;
186
use agent::agent::agent_loop::protocol::{
@@ -26,6 +14,17 @@ use agent::agent::protocol::{
2614
SendApprovalResultArgs,
2715
SendPromptArgs,
2816
};
17+
use clap::Args;
18+
use eyre::{
19+
Result,
20+
bail,
21+
};
22+
use serde::{
23+
Deserialize,
24+
Serialize,
25+
};
26+
use tokio::io::AsyncWriteExt;
27+
use tracing::warn;
2928

3029
// use crate::chat::{
3130
// ActiveState,
@@ -101,8 +100,10 @@ impl RunArgs {
101100

102101
// Check for exit conditions
103102
match &evt {
104-
AgentEvent::AgentLoop(evt) => if let AgentLoopEventKind::UserTurnEnd(_) = &evt.kind {
105-
break;
103+
AgentEvent::AgentLoop(evt) => {
104+
if let AgentLoopEventKind::UserTurnEnd(_) = &evt.kind {
105+
break;
106+
}
106107
},
107108
AgentEvent::RequestError(loop_error) => bail!("agent encountered an error: {:?}", loop_error),
108109
AgentEvent::ApprovalRequest { id, tool_use, context } => {

0 commit comments

Comments
 (0)