feat(tui): implement agent turn engine for background processing and enhance input handling
This commit is contained in:
@@ -37,23 +37,23 @@ pub fn run_daemon() -> Result<()> {
|
||||
let addr = socket_path.to_string_lossy().to_string();
|
||||
|
||||
let server = IpcServer::bind_unix(&addr)?;
|
||||
eprintln!("daemon: listening on {addr}");
|
||||
tracing::info!("daemon listening on {addr}");
|
||||
|
||||
loop {
|
||||
let conn = match server.accept() {
|
||||
Ok(c) => c,
|
||||
Err(e) => {
|
||||
eprintln!("daemon: accept error: {e}");
|
||||
tracing::error!("daemon accept error: {e}");
|
||||
break;
|
||||
}
|
||||
};
|
||||
eprintln!("daemon: client connected");
|
||||
tracing::info!("daemon client connected");
|
||||
|
||||
if let Err(e) = handle_daemon_client(conn, &mut state) {
|
||||
eprintln!("daemon: error handling client: {e}");
|
||||
tracing::error!("daemon error handling client: {e}");
|
||||
}
|
||||
|
||||
eprintln!("daemon: client disconnected, waiting for next connection...");
|
||||
tracing::info!("daemon client disconnected");
|
||||
state.save_settings();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user