aKode fase 5: test e snapshot adeguati alla rinomina, 429 distinto (ProviderRateLimited), cargo fmt dopo il cambio dei prefissi

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
andrea.difonzo
2026-11-11 12:47:01 +01:00
parent 8b73331037
commit ad43f9281a
919 changed files with 2358 additions and 2430 deletions

View File

@@ -1,16 +1,16 @@
use std::path::PathBuf;
use std::time::Duration;
use anyhow::Context;
use chrono::DateTime;
use clap::Parser;
use clap::ValueEnum;
use akode_core::config::ConfigBuilder;
use akode_state::LogQuery;
use akode_state::LogRow;
use akode_state::SqliteConfig;
use akode_state::StateRuntime;
use akode_utils_absolute_path::AbsolutePathBuf;
use anyhow::Context;
use chrono::DateTime;
use clap::Parser;
use clap::ValueEnum;
use owo_colors::OwoColorize;
#[derive(Debug, Parser)]

View File

@@ -1,9 +1,9 @@
//! Preserve config overrides across command boundaries without changing typed child arguments.
use crate::MultitoolCli;
use akode_utils_cli::collect_config_overrides;
use clap::CommandFactory;
use clap::FromArgMatches;
use akode_utils_cli::collect_config_overrides;
use std::ffi::OsString;
pub(super) fn try_parse_from(

View File

@@ -2,8 +2,8 @@
use std::io::IsTerminal;
use anyhow::Result;
use akode_app_server_daemon::InstallRequest;
use anyhow::Result;
pub(crate) fn confirm_install(request: &InstallRequest, yes: bool) -> Result<bool> {
eprintln!("{}", describe_install(request));

View File

@@ -6,7 +6,6 @@ mod seatbelt;
use std::path::PathBuf;
use std::process::Stdio;
use anyhow::Context as _;
use akode_config::LoaderOverrides;
use akode_core::config::Config;
use akode_core::config::ConfigBuilder;
@@ -31,6 +30,7 @@ use akode_sandboxing::seatbelt::create_seatbelt_command_args;
use akode_sandboxing::with_managed_mitm_ca_readable_root;
use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context as _;
use tokio::process::Child;
use tokio::process::Command as TokioCommand;
use toml::Value as TomlValue;

View File

@@ -26,8 +26,6 @@ use std::sync::Arc;
use std::time::Duration;
use std::time::Instant;
use anyhow::Context;
use clap::Parser;
use akode_api::ApiError;
use akode_api::ResponsesWebsocketClient;
use akode_api::TransportError;
@@ -51,9 +49,9 @@ use akode_install_context::CodexPackageLayout;
use akode_install_context::InstallContext;
use akode_install_context::InstallMethod;
use akode_install_context::StandalonePlatform;
use akode_login::AKODE_API_KEY_ENV_VAR;
use akode_login::AuthDotJson;
use akode_login::AuthManager;
use akode_login::AKODE_API_KEY_ENV_VAR;
use akode_login::CodexAuth;
use akode_login::OPENAI_API_KEY_ENV_VAR;
use akode_login::default_client::create_client_without_request_logging;
@@ -68,6 +66,8 @@ use akode_terminal_detection::TerminalName;
use akode_terminal_detection::terminal_info;
use akode_tui::Cli as TuiCli;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use clap::Parser;
use http::HeaderMap;
use http::HeaderValue;
use http::Method;
@@ -3111,8 +3111,8 @@ mod tests {
use std::net::TcpListener;
use std::sync::Mutex;
use clap::Parser;
use akode_protocol::config_types::SandboxMode;
use clap::Parser;
use pretty_assertions::assert_eq;
use super::*;

View File

@@ -2,9 +2,9 @@
source: cli/src/doctor/output.rs
expression: "rendered.replace('\\u{1b}', \"<ESC>\")"
---
<ESC>[38;5;10m✓<ESC>[39m state <ESC>[2m<ESC>[38;5;117m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;117m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117mcodex doctor<ESC>[39m<ESC>[0m
<ESC>[38;5;10m✓<ESC>[39m state <ESC>[2m<ESC>[38;5;117m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;117m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117makode doctor<ESC>[39m<ESC>[0m
<ESC>[38;5;240mlocations <ESC>[39m see <ESC>[38;5;117m./logs<ESC>[39m, <ESC>[38;5;117m../goals<ESC>[39m. C:\logs, D:/goals. c:\logs, \\server\share\logs, \\?\C:\logs, \\?\UNC\server\share\logs, \\.\pipe\codex, \??\C:\logs, \DosDevices\C:\logs, \rooted. <ESC>[38;5;117mhttp://localhost:8080<ESC>[39m: <ESC>[38;5;117mhttps://example.com<ESC>[39m; <ESC>[38;5;117mwss://example.com<ESC>[39m) and <ESC>[38;5;117m/tmp/my data/logs_2.sqlite<ESC>[39m
<ESC>[38;5;214m⚠<ESC>[39m state <ESC>[38;5;117m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;117m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117mcodex doctor<ESC>[39m
<ESC>[38;5;214m⚠<ESC>[39m state <ESC>[38;5;117m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;117m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117makode doctor<ESC>[39m
<ESC>[38;5;240mlocations <ESC>[39m see <ESC>[38;5;117m./logs<ESC>[39m, <ESC>[38;5;117m../goals<ESC>[39m. C:\logs, D:/goals. c:\logs, \\server\share\logs, \\?\C:\logs, \\?\UNC\server\share\logs, \\.\pipe\codex, \??\C:\logs, \DosDevices\C:\logs, \rooted. <ESC>[38;5;117mhttp://localhost:8080<ESC>[39m: <ESC>[38;5;117mhttps://example.com<ESC>[39m; <ESC>[38;5;117mwss://example.com<ESC>[39m) and <ESC>[38;5;117m/tmp/my data/logs_2.sqlite<ESC>[39m
<ESC>[38;5;196m✗<ESC>[39m state <ESC>[38;5;196m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;196m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117mcodex doctor<ESC>[39m
<ESC>[38;5;196m✗<ESC>[39m state <ESC>[38;5;196m/tmp/logs_2.sqlite<ESC>[39m, <ESC>[38;5;196m~/goals_1.sqlite<ESC>[39m integrity check; try <ESC>[38;5;117m--summary<ESC>[39m or <ESC>[38;5;117makode doctor<ESC>[39m
<ESC>[38;5;240mlocations <ESC>[39m see <ESC>[38;5;196m./logs<ESC>[39m, <ESC>[38;5;196m../goals<ESC>[39m. C:\logs, D:/goals. c:\logs, \\server\share\logs, \\?\C:\logs, \\?\UNC\server\share\logs, \\.\pipe\codex, \??\C:\logs, \DosDevices\C:\logs, \rooted. <ESC>[38;5;196mhttp://localhost:8080<ESC>[39m: <ESC>[38;5;196mhttps://example.com<ESC>[39m; <ESC>[38;5;196mwss://example.com<ESC>[39m) and <ESC>[38;5;196m/tmp/my data/logs_2.sqlite<ESC>[39m

View File

@@ -3,11 +3,11 @@ mod exit_status;
pub mod local_config;
pub(crate) mod login;
use clap::Args;
use clap::Parser;
use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cli::CliConfigOverrides;
use akode_utils_cli::ProfileV2Name;
use clap::Args;
use clap::Parser;
use std::path::PathBuf;
pub use debug_sandbox::run_command_under_landlock;

View File

@@ -1,5 +1,3 @@
use anyhow::Context;
use anyhow::Result;
use akode_app_server::in_process::EmbeddedNetworkPolicy;
use akode_core::config::Config;
use akode_core::config::ConfigBuilder;
@@ -8,6 +6,8 @@ use akode_core::config::LoaderOverrides;
use akode_core::config::find_codex_home;
use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use anyhow::Result;
pub async fn load_config(
config_overrides: &CliConfigOverrides,

View File

@@ -1,8 +1,3 @@
use clap::Args;
use clap::CommandFactory;
use clap::Parser;
use clap_complete::Shell;
use clap_complete::generate;
use akode_app_server_daemon::BootstrapOptions as AppServerBootstrapOptions;
use akode_app_server_daemon::LifecycleCommand as AppServerLifecycleCommand;
use akode_arg0::Arg0DispatchPaths;
@@ -29,6 +24,11 @@ use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cli::CliConfigOverrides;
use akode_utils_cli::ProfileV2Name;
use akode_utils_cli::SharedCliOptions;
use clap::Args;
use clap::CommandFactory;
use clap::Parser;
use clap_complete::Shell;
use clap_complete::generate;
use std::collections::HashSet;
use std::io::IsTerminal;
use std::io::Write;
@@ -2599,9 +2599,9 @@ fn print_completion(cmd: CompletionCommand) {
#[cfg(test)]
mod tests {
use super::*;
use assert_matches::assert_matches;
use akode_protocol::ThreadId;
use akode_tui::TokenUsage;
use assert_matches::assert_matches;
use pretty_assertions::assert_eq;
#[test]
@@ -3745,7 +3745,7 @@ enabled = true
vec![
"Token usage: total=2 input=0 output=2",
"To continue this session, run:",
" \u{1b}[36mcodex resume 123e4567-e89b-12d3-a456-426614174000\u{1b}[39m",
" \u{1b}[36makode resume 123e4567-e89b-12d3-a456-426614174000\u{1b}[39m",
]
);
}
@@ -3777,8 +3777,8 @@ enabled = true
vec![
"Token usage: total=2 input=0 output=2",
"To continue this session, run:",
" \u{1b}[36mcodex resume 123e4567-e89b-12d3-a456-426614174000\u{1b}[39m",
"Or run \u{1b}[36mcodex resume\u{1b}[39m and select \u{1b}[36mmy-thread\u{1b}[39m.",
" \u{1b}[36makode resume 123e4567-e89b-12d3-a456-426614174000\u{1b}[39m",
"Or run \u{1b}[36makode resume\u{1b}[39m and select \u{1b}[36mmy-thread\u{1b}[39m.",
]
);
}

View File

@@ -1,7 +1,3 @@
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use clap::Parser;
use akode_core::config::Config;
use akode_core::config::ConfigOverrides;
use akode_core::config::LoaderOverrides;
@@ -18,6 +14,10 @@ use akode_core_plugins::marketplace_remove::MarketplaceRemoveOutcome;
use akode_core_plugins::marketplace_remove::MarketplaceRemoveRequest;
use akode_core_plugins::marketplace_remove::remove_marketplace;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use clap::Parser;
use serde::Serialize;
use std::collections::HashMap;
use std::collections::HashSet;

View File

@@ -1,12 +1,6 @@
use std::collections::HashMap;
use std::sync::Arc;
use anyhow::Context;
use anyhow::Result;
use anyhow::anyhow;
use anyhow::bail;
use clap::ArgGroup;
use clap::builder::TypedValueParser;
use akode_config::types::AppToolApproval;
use akode_config::types::McpServerAuth;
use akode_config::types::McpServerConfig;
@@ -42,6 +36,12 @@ use akode_rmcp_client::resolve_mcp_oauth_callback_url;
use akode_utils_cli::CliConfigOverrides;
use akode_utils_cli::format_env_display;
use akode_utils_redacted_string::RedactedString;
use anyhow::Context;
use anyhow::Result;
use anyhow::anyhow;
use anyhow::bail;
use clap::ArgGroup;
use clap::builder::TypedValueParser;
use crate::local_config;
use crate::mcp_login::McpLoginMode;

View File

@@ -1,9 +1,9 @@
//! Verifies MCP argument handling and managed networking in standalone commands.
use clap::Parser;
use akode_http_client::ClientRouteClass;
use akode_http_client::HttpError;
use akode_http_client::NetworkPolicyDenied;
use clap::Parser;
use pretty_assertions::assert_eq;
use std::path::PathBuf;
use std::time::Duration;

View File

@@ -11,9 +11,6 @@ use std::io::IsTerminal;
use std::io::Write;
use std::sync::Arc;
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use akode_config::McpServerOAuthConfig;
use akode_config::types::AuthKeyringBackendKind;
use akode_config::types::OAuthCredentialsStoreMode;
@@ -23,6 +20,9 @@ use akode_mcp::should_retry_without_scopes;
use akode_rmcp_client::McpOAuthClientRegistration;
use akode_rmcp_client::perform_oauth_login;
use akode_rmcp_client::perform_oauth_login_with_callback_input;
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use crossterm::event::Event;
use crossterm::event::EventStream;
use crossterm::event::KeyCode;

View File

@@ -2,14 +2,14 @@
//! Other SQLite clients must remain stopped during replacement, and NFS must enforce
//! cross-client POSIX locks.
use anyhow::Context;
use anyhow::ensure;
use clap::Parser;
use akode_config::LoaderOverrides;
use akode_core::config::ConfigBuilder;
use akode_state::NfsDbMigration;
use akode_state::NfsDbMigrationOutcome;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use anyhow::ensure;
use clap::Parser;
use owo_colors::OwoColorize;
use std::path::PathBuf;

View File

@@ -5,8 +5,6 @@ use std::path::Path;
use std::time::Duration;
use std::time::Instant;
use anyhow::Context;
use clap::Parser;
use akode_core::config::ConfigBuilder;
use akode_protocol::ThreadId;
use akode_thread_store::LocalThreadStore;
@@ -17,6 +15,8 @@ use akode_thread_store::RolloutMigrationProgress;
use akode_thread_store::RolloutMigrationReport;
use akode_thread_store::RolloutMigrationStatus;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use clap::Parser;
#[derive(Debug, Parser)]
pub(crate) struct MigrateRolloutsCommand {

View File

@@ -1,7 +1,3 @@
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use clap::Parser;
use akode_core::config::Config;
use akode_core::config::find_codex_home;
use akode_core::plugins_manager_for_config;
@@ -24,6 +20,10 @@ use akode_plugin::PluginId;
use akode_plugin::validate_plugin_segment;
use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cli::CliConfigOverrides;
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use clap::Parser;
use serde::Serialize;
use std::collections::HashMap;
use std::io;

View File

@@ -1,3 +1,6 @@
use akode_arg0::Arg0DispatchPaths;
use akode_tui::Cli as TuiCli;
use akode_utils_cli::CliConfigOverrides;
use clap::Arg;
use clap::ArgMatches;
use clap::Command;
@@ -6,9 +9,6 @@ use clap::Parser;
use clap::builder::NonEmptyStringValueParser;
use clap::error::ErrorKind;
use clap::parser::ValueSource;
use akode_arg0::Arg0DispatchPaths;
use akode_tui::Cli as TuiCli;
use akode_utils_cli::CliConfigOverrides;
use crate::InteractiveRemoteOptions;
use crate::SessionArchiveConfigOverrides;

View File

@@ -1,13 +1,13 @@
use std::path::PathBuf;
use anyhow::Context;
use clap::ArgAction;
use clap::ArgGroup;
use clap::Parser;
use akode_core::config::ConfigBuilder;
use akode_core::config::edit::ConfigEditsBuilder;
use akode_core::config::find_codex_home;
use akode_utils_cli::ProfileV2Name;
use anyhow::Context;
use clap::ArgAction;
use clap::ArgGroup;
use clap::Parser;
use toml::Value as TomlValue;
#[derive(Debug, Parser)]

View File

@@ -26,7 +26,7 @@ Options:
--strict-config
Error out when config.toml contains fields that are not recognized by
this version of Codex
this version of aKode
--disable <FEATURE>
Disable a feature (repeatable). Equivalent to `-c

View File

@@ -1,6 +1,5 @@
---
source: cli/src/main.rs
assertion_line: 3324
expression: "errors.join(\"\\n\")"
---
akode --worktree login: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`
@@ -9,5 +8,5 @@ akode fork --worktree --last: `akode fork --worktree` requires an explicit sessi
akode exec resume --worktree session: `--worktree` cannot resume an existing session; use `akode exec fork --worktree`
akode exec review --worktree: `--worktree` is not supported for code review
akode resume --worktree session: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`
codex archive session --worktree: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`
codex queue --thread session --message hi --worktree: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`
akode archive session --worktree: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`
akode queue --thread session --message hi --worktree: `--worktree` supports new interactive sessions, `akode fork`, `akode exec`, and `akode exec fork`

View File

@@ -131,7 +131,7 @@ fn agents_reject_inputs_that_cannot_be_applied() -> Result<()> {
#[test]
fn app_server_emits_json_info_events() -> Result<()> {
let codex_home = TempDir::new()?;
let event = app_server_json_shutdown_event("codex", &["app-server"], codex_home.path())?;
let event = app_server_json_shutdown_event("akode", &["app-server"], codex_home.path())?;
assert_eq!(
event,

View File

@@ -7,10 +7,10 @@ use std::process::Command;
use std::time::Duration;
use std::time::Instant;
use akode_utils_cargo_bin::copy_executable;
use anyhow::Context;
use anyhow::Result;
use anyhow::ensure;
use akode_utils_cargo_bin::copy_executable;
use serde_json::Value;
use tempfile::TempDir;

View File

@@ -1,9 +1,9 @@
//! Exercises daemon installation from the Windows WinGet archive layout.
#![cfg(windows)]
use akode_utils_cargo_bin::copy_executable;
use anyhow::Result;
use anyhow::ensure;
use akode_utils_cargo_bin::copy_executable;
use pretty_assertions::assert_eq;
use serde_json::Value;
use sha2::Digest;
@@ -29,8 +29,8 @@ fn winget_package_starts_and_reselects_daemon() -> Result<()> {
for helper in [
"akode-code-mode-host.exe",
"akode-path/rg.exe",
"akode-resources/codex-command-runner.exe",
"akode-resources/codex-windows-sandbox-setup.exe",
"akode-resources/akode-command-runner.exe",
"akode-resources/akode-windows-sandbox-setup.exe",
] {
std::fs::write(package.join(helper), b"runtime fixture")?;
}

View File

@@ -246,7 +246,7 @@ async fn daemon_startup(command: &str) -> Result<()> {
let managed = home
.path()
.join("packages/app-server-daemon/current/bin")
.join(if cfg!(windows) { "akode.exe" } else { "codex" });
.join(if cfg!(windows) { "akode.exe" } else { "akode" });
fs::create_dir_all(home.path().join("packages/app-server-daemon/current/bin"))?;
// Hard links change the executable's ctime and invalidate Rosetta's translation cache.
#[cfg(unix)]

View File

@@ -1,8 +1,8 @@
use std::path::Path;
use anyhow::Result;
use akode_state::StateRuntime;
use akode_utils_absolute_path::test_support::PathExt;
use anyhow::Result;
use predicates::str::contains;
use tempfile::TempDir;

View File

@@ -3,10 +3,10 @@ use std::path::Path;
use std::process::Command;
use std::process::Stdio;
use anyhow::Context as _;
use anyhow::Result;
use akode_state::SqliteConfig;
use akode_utils_absolute_path::AbsolutePathBuf;
use anyhow::Context as _;
use anyhow::Result;
use pretty_assertions::assert_eq;
use regex_lite::Regex;
use serde_json::Value;

View File

@@ -4,15 +4,15 @@ use std::ffi::OsString;
use std::path::PathBuf;
use std::time::Duration;
#[cfg(unix)]
use anyhow::Context;
use anyhow::Result;
use app_test_support::TestAppServer;
use akode_app_server_protocol::RequestId;
use akode_config::loader::project_trust_key;
use akode_state::SqliteConfig;
use akode_utils_absolute_path::AbsolutePathBuf;
use akode_utils_cargo_bin::copy_executable;
#[cfg(unix)]
use anyhow::Context;
use anyhow::Result;
use app_test_support::TestAppServer;
use pretty_assertions::assert_eq;
use serde_json::Value;
use serde_json::json;

View File

@@ -21,8 +21,6 @@ use std::time::Duration;
#[cfg(unix)]
use std::time::Instant;
use anyhow::Context;
use anyhow::Result;
use akode_exec_server::EnvironmentInfo;
use akode_exec_server::ExecParams;
use akode_exec_server::ExecServerClient;
@@ -35,6 +33,8 @@ use akode_http_client::HttpClientFactory;
use akode_http_client::OutboundProxyPolicy;
use akode_utils_cargo_bin::copy_executable;
use akode_utils_path_uri::PathUri;
use anyhow::Context;
use anyhow::Result;
use futures::SinkExt;
use futures::StreamExt;
use predicates::prelude::PredicateBooleanExt;

View File

@@ -224,10 +224,10 @@ fn exec_server_websocket_auth_rejects_invalid_configuration() -> Result<()> {
#[tokio::test]
async fn app_server_executor_auth_supports_tokens_and_legacy_configuration() -> Result<()> {
use app_test_support::TestAppServer;
use app_test_support::to_response;
use akode_app_server_protocol::EnvironmentInfoResponse;
use akode_app_server_protocol::RequestId;
use app_test_support::TestAppServer;
use app_test_support::to_response;
#[derive(Debug, PartialEq)]
enum Source {

View File

@@ -1,7 +1,7 @@
use anyhow::Result;
use akode_config::CONFIG_TOML_FILE;
use akode_core_plugins::installed_marketplaces::marketplace_install_root;
use akode_utils_absolute_path::AbsolutePathBuf;
use anyhow::Result;
use predicates::str::contains;
use pretty_assertions::assert_eq;
use serde_json::json;

View File

@@ -1,8 +1,8 @@
use anyhow::Result;
use akode_config::MarketplaceConfigUpdate;
use akode_config::record_user_marketplace;
use akode_core_plugins::installed_marketplaces::marketplace_install_root;
use akode_utils_absolute_path::canonicalize_existing_preserving_symlinks;
use anyhow::Result;
use predicates::str::contains;
use pretty_assertions::assert_eq;
use serde_json::json;

View File

@@ -1,6 +1,6 @@
use anyhow::Result;
use akode_core_plugins::installed_marketplaces::marketplace_install_root;
use akode_utils_absolute_path::AbsolutePathBuf;
use anyhow::Result;
use predicates::str::contains;
use pretty_assertions::assert_eq;
use serde_json::json;

View File

@@ -1,10 +1,10 @@
use std::collections::BTreeMap;
use std::path::Path;
use anyhow::Result;
use akode_config::types::McpServerTransportConfig;
use akode_core::config::edit::ConfigEditsBuilder;
use akode_core::config::load_global_mcp_servers;
use anyhow::Result;
use predicates::str::contains;
use pretty_assertions::assert_eq;
use tempfile::TempDir;

View File

@@ -6,11 +6,11 @@ use std::path::Path;
use std::time::Duration;
use std::time::Instant;
use anyhow::Result;
use akode_config::types::McpServerTransportConfig;
use akode_core::config::edit::ConfigEditsBuilder;
use akode_core::config::load_global_mcp_servers;
use akode_login::AKODE_API_KEY_ENV_VAR;
use anyhow::Result;
use predicates::prelude::PredicateBooleanExt;
use predicates::str::contains;
use pretty_assertions::assert_eq;

View File

@@ -5,10 +5,10 @@ use std::process::Output;
use std::process::Stdio;
use std::time::Duration;
use akode_core::config::load_global_mcp_servers;
use anyhow::Context;
use anyhow::Result;
use anyhow::bail;
use akode_core::config::load_global_mcp_servers;
use pretty_assertions::assert_eq;
use serde_json::Value;
use serde_json::json;

View File

@@ -2,8 +2,8 @@
#![cfg(unix)]
use anyhow::Result;
use akode_state::SqliteConfig;
use anyhow::Result;
use predicates::prelude::PredicateBooleanExt;
use predicates::str::contains;
use pretty_assertions::assert_eq;

View File

@@ -1,9 +1,9 @@
use anyhow::Context;
use anyhow::Result;
use akode_config::CONFIG_TOML_FILE;
use akode_config::MarketplaceConfigUpdate;
use akode_config::record_user_marketplace;
use akode_utils_absolute_path::canonicalize_existing_preserving_symlinks;
use anyhow::Context;
use anyhow::Result;
use predicates::prelude::PredicateBooleanExt;
use predicates::str::contains;
use pretty_assertions::assert_eq;

View File

@@ -263,9 +263,6 @@ async fn run_remote_queue_command(response: QueueResponse) -> Result<(Output, Va
async fn remote_session_commands_with_workload_identity_use_server_auth() -> Result<()> {
use std::time::Duration;
use app_test_support::MockResponsesConfig;
use app_test_support::TestAppServer;
use app_test_support::create_final_assistant_message_sse_response;
use akode_app_server_client::AppServerEvent;
use akode_app_server_client::DEFAULT_IN_PROCESS_CHANNEL_CAPACITY;
use akode_app_server_client::RemoteAppServerClient;
@@ -288,6 +285,9 @@ async fn remote_session_commands_with_workload_identity_use_server_auth() -> Res
use akode_app_server_protocol::TurnStatus;
use akode_protocol::shell_environment::OPENAI_FEDERATION_RULE_ID_ENV_VAR;
use akode_protocol::shell_environment::OPENAI_IDENTITY_TOKEN_FILE_ENV_VAR;
use app_test_support::MockResponsesConfig;
use app_test_support::TestAppServer;
use app_test_support::create_final_assistant_message_sse_response;
use core_test_support::responses;
use tokio::process::Command;
use tokio::time::timeout;

View File

@@ -1,9 +1,5 @@
//! Exercise trace acceptance through the CLI app-server and its offline reducer.
use anyhow::Result;
use app_test_support::MockResponsesConfig;
use app_test_support::TestAppServer;
use app_test_support::create_mock_responses_server_sequence;
use akode_app_server_protocol::AgentMessageDeltaNotification;
use akode_app_server_protocol::ClientRequest;
use akode_app_server_protocol::RequestId;
@@ -20,6 +16,10 @@ use akode_rollout_trace::ConversationRole;
use akode_rollout_trace::ExecutionStatus;
use akode_rollout_trace::ProducerRef;
use akode_rollout_trace::RolloutTrace;
use anyhow::Result;
use app_test_support::MockResponsesConfig;
use app_test_support::TestAppServer;
use app_test_support::create_mock_responses_server_sequence;
use core_test_support::responses;
use core_test_support::streaming_sse::StreamingSseChunk;
use core_test_support::streaming_sse::start_streaming_sse_server;

View File

@@ -7,10 +7,10 @@ use std::path::Path;
use std::process::Command;
use std::time::Duration;
use anyhow::Context as _;
use akode_utils_pty::SpawnedProcess;
use akode_utils_pty::TerminalSize;
use akode_utils_pty::spawn_pty_process;
use anyhow::Context as _;
use pretty_assertions::assert_eq;
use tempfile::TempDir;

View File

@@ -6,7 +6,7 @@ Error: failed to load configuration
Caused by:
0: [AKODE_HOME]/config.toml:<line>:<column>: unknown key `backslash` in keybinding `backslash`. Use a printable character (for example `a`), function keys (`f1`-`f24`), or one of: enter, tab, backspace, esc, delete, arrows, home/end, page-up/page-down, space, minus.
See the Codex keymap documentation for supported actions and examples.
See the aKode keymap documentation for supported actions and examples.
1: unknown key `backslash` in keybinding `backslash`. Use a printable character (for example `a`), function keys (`f1`-`f24`), or one of: enter, tab, backspace, esc, delete, arrows, home/end, page-up/page-down, space, minus.
See the Codex keymap documentation for supported actions and examples.
See the aKode keymap documentation for supported actions and examples.
in `tui.keymap.editor.insert_newline`

View File

@@ -271,7 +271,7 @@ trust_level = "trusted"
let _daemon = if backend == "daemon" {
let bin = home.join("packages/app-server-daemon/current/bin");
fs::create_dir_all(&bin)?;
let managed = bin.join(if cfg!(windows) { "akode.exe" } else { "codex" });
let managed = bin.join(if cfg!(windows) { "akode.exe" } else { "akode" });
// Hard links change the executable's ctime and invalidate Rosetta's translation cache.
#[cfg(unix)]
std::os::unix::fs::symlink(program.canonicalize()?, &managed)?;