Riapplica la fase 5 di aKode (86e7c72e) sulla base ripulita:
- crate codex-* -> akode-*, codex-rs -> akode-rs, codex-cli -> akode-cli, binario e ausiliari akode;
- ~/.codex -> ~/.akode, CODEX_HOME -> AKODE_HOME, variabili CODEX_* -> AKODE_*, .codex/ -> .akode/ di progetto;
nessun fallback a ~/.codex o a CODEX_*;
- testi per l'utente "Codex" -> "aKode"; testi verso il modello e istruzioni di sistema invariati;
- snapshot insta rinominati (non ancora rigenerati).
I conflitti con la base ripulita sono stati risolti riapplicando la rinomina ai file senza le
funzioni di imeAI (script di mappa dei token per file).
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
31 lines
1.0 KiB
Rust
31 lines
1.0 KiB
Rust
//! Observe the latest startup attempt without polling it or initiating a retry.
|
|
|
|
use akode_protocol::mcp::McpServerConnectionStatus as Status;
|
|
|
|
use super::AsyncManagedClient;
|
|
use super::StartupOutcomeError;
|
|
|
|
impl AsyncManagedClient {
|
|
pub(crate) async fn connection_status(&self) -> Status {
|
|
if self.cancel_token.is_cancelled() {
|
|
return Status::Cancelled;
|
|
}
|
|
let outcome = self.client.peek().cloned();
|
|
match outcome {
|
|
Some(Ok(client)) => {
|
|
if client.client.is_closed().await {
|
|
Status::Failed
|
|
} else {
|
|
Status::Connected
|
|
}
|
|
}
|
|
Some(Err(error)) if error.is_authentication_required() => {
|
|
Status::AuthenticationRequired
|
|
}
|
|
Some(Err(StartupOutcomeError::Failed { .. })) => Status::Failed,
|
|
Some(Err(StartupOutcomeError::Cancelled)) => Status::Cancelled,
|
|
None => Status::Starting,
|
|
}
|
|
}
|
|
}
|