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:
@@ -1,7 +1,7 @@
|
||||
use anyhow::Result;
|
||||
use akode_agent_extension::AgentInvocation;
|
||||
use akode_agent_extension::AgentRunner;
|
||||
use akode_protocol::protocol::EventMsg;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::skip_if_no_network;
|
||||
use core_test_support::test_codex::test_codex;
|
||||
|
||||
@@ -15,16 +15,6 @@ pub use session_isolation::IsolatedSessionExtensions;
|
||||
pub use session_isolation::SessionIsolation;
|
||||
pub use tool_policy::ToolPolicy;
|
||||
|
||||
pub use capabilities::ConversationHistorySnapshot;
|
||||
pub use capabilities::ExtensionEventSink;
|
||||
pub use capabilities::ExtensionMetrics;
|
||||
pub use capabilities::ExtensionWarning;
|
||||
pub use capabilities::NoopExtensionEventSink;
|
||||
pub use capabilities::NoopResponseItemInjector;
|
||||
pub use capabilities::ResponseItemInjectionFuture;
|
||||
pub use capabilities::ResponseItemInjector;
|
||||
pub use capabilities::record_catalog_entries;
|
||||
pub use catalog_refresh::CatalogRefreshBackoff;
|
||||
pub use akode_context_fragments::ContextualUserFragment;
|
||||
pub use akode_mcp::McpProtocolMode;
|
||||
pub use akode_mcp::ToolInfo as McpToolInfo;
|
||||
@@ -52,6 +42,16 @@ pub use akode_tools::TurnItemEmissionFuture;
|
||||
pub use akode_tools::TurnItemEmitter;
|
||||
pub use akode_tools::parse_tool_input_schema;
|
||||
pub use akode_tools::parse_tool_input_schema_without_compaction;
|
||||
pub use capabilities::ConversationHistorySnapshot;
|
||||
pub use capabilities::ExtensionEventSink;
|
||||
pub use capabilities::ExtensionMetrics;
|
||||
pub use capabilities::ExtensionWarning;
|
||||
pub use capabilities::NoopExtensionEventSink;
|
||||
pub use capabilities::NoopResponseItemInjector;
|
||||
pub use capabilities::ResponseItemInjectionFuture;
|
||||
pub use capabilities::ResponseItemInjector;
|
||||
pub use capabilities::record_catalog_entries;
|
||||
pub use catalog_refresh::CatalogRefreshBackoff;
|
||||
pub use contributors::AccessedSelectedCapabilityRoot;
|
||||
pub use contributors::ApprovalDecision;
|
||||
pub use contributors::ApprovalDecisionInput;
|
||||
|
||||
@@ -7,12 +7,12 @@ use std::future::Future;
|
||||
use std::time::Duration;
|
||||
|
||||
use crate::GuardianReviewDetails;
|
||||
use anyhow::anyhow;
|
||||
use akode_protocol::protocol::ErrorEvent;
|
||||
use akode_protocol::protocol::Event;
|
||||
use akode_protocol::protocol::EventMsg;
|
||||
use akode_protocol::turn_input::TurnInputRequest;
|
||||
use akode_protocol::turn_input::TurnInputSubmission;
|
||||
use anyhow::anyhow;
|
||||
use tokio::time::Instant;
|
||||
use tokio_util::sync::CancellationToken;
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@ use std::sync::Arc;
|
||||
use std::sync::Mutex;
|
||||
use std::time::Duration;
|
||||
|
||||
use anyhow::Result;
|
||||
use akode_core::config::Config;
|
||||
use akode_core::config::ConfigBuilder;
|
||||
use akode_core::config::LoaderOverrides;
|
||||
@@ -58,6 +57,7 @@ use akode_protocol::protocol::SessionSource;
|
||||
use akode_protocol::protocol::TruncationPolicy;
|
||||
use akode_protocol::security_risk::SecurityRiskScore;
|
||||
use akode_protocol_test_support::uuid_v7_item_id_generator_for_test;
|
||||
use anyhow::Result;
|
||||
use core_test_support::ThreadIdle;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::responses::WebSocketConnectionConfig;
|
||||
|
||||
@@ -2,11 +2,11 @@
|
||||
|
||||
use super::super::config::DEFAULT_PARENT_COMPACTION_TOKENS;
|
||||
use super::*;
|
||||
use anyhow::Result;
|
||||
use akode_history::CompactionCheckpoint;
|
||||
use akode_history::ResponseItemEnvelope;
|
||||
use akode_protocol::ResponseItemId;
|
||||
use akode_protocol::models::InternalChatMessageMetadataPassthrough;
|
||||
use anyhow::Result;
|
||||
use pretty_assertions::assert_eq;
|
||||
|
||||
#[test]
|
||||
|
||||
@@ -8,9 +8,9 @@ use crate::async_scorer::sampler::tests::connect_sampler;
|
||||
use crate::async_scorer::sampler::tests::proxy_websocket_servers;
|
||||
use crate::async_scorer::sampler::tests::sample_request;
|
||||
use crate::async_scorer::sampler::tests::sampler_config;
|
||||
use anyhow::Result;
|
||||
use akode_api::ResponseEvent;
|
||||
use akode_api::ResponseInterrupt;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::responses::ev_assistant_message;
|
||||
use core_test_support::responses::ev_completed;
|
||||
|
||||
@@ -8,13 +8,13 @@ use super::super::tests::sample_request;
|
||||
use super::super::tests::sampler_config;
|
||||
use super::*;
|
||||
use crate::async_scorer::request::PreparedRequest;
|
||||
use anyhow::Result;
|
||||
use akode_guardian_context::TranscriptCursor;
|
||||
use akode_history::ResponseItemEnvelope;
|
||||
use akode_login::AuthManager;
|
||||
use akode_login::CodexAuth;
|
||||
use akode_model_provider::create_model_provider;
|
||||
use akode_model_provider_info::ModelProviderInfo;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::skip_if_no_network;
|
||||
use pretty_assertions::assert_eq;
|
||||
|
||||
@@ -4,13 +4,13 @@ use super::connect_sampler;
|
||||
use super::proxy_websocket_servers;
|
||||
use super::sample_request;
|
||||
use super::sampler_config;
|
||||
use anyhow::Result;
|
||||
use akode_login::AuthManager;
|
||||
use akode_login::CodexAuth;
|
||||
use akode_login::ExternalAuth;
|
||||
use akode_login::ExternalAuthFuture;
|
||||
use akode_login::ExternalAuthRefreshContext;
|
||||
use akode_model_provider::create_model_provider;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::responses::WebSocketConnectionConfig;
|
||||
use pretty_assertions::assert_eq;
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
use anyhow::Result;
|
||||
use akode_api::ApiError;
|
||||
use akode_context_fragments::RenderedFragment;
|
||||
use akode_extension_api::ContextualUserFragment;
|
||||
@@ -22,6 +21,7 @@ use akode_protocol::models::ContentItem;
|
||||
use akode_protocol::models::ResponseItem;
|
||||
use akode_protocol::openai_models::ReasoningEffort;
|
||||
use akode_protocol_test_support::uuid_v7_item_id_generator_for_test;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::responses::WebSocketConnectionConfig;
|
||||
use core_test_support::responses::ev_assistant_message;
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
use std::path::Path;
|
||||
|
||||
use anyhow::Result;
|
||||
use akode_extension_api::McpToolInfo;
|
||||
use akode_extension_api::McpToolSource;
|
||||
use akode_guardian_context::TrustedTool;
|
||||
use akode_guardian_context::TrustedToolSource;
|
||||
use akode_login::CodexAuth;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::skip_if_no_network;
|
||||
use core_test_support::test_codex::test_codex;
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
use crate::EvidenceId;
|
||||
use crate::GUARDIAN_BOARD_NAMESPACE;
|
||||
use crate::sampling::context_input;
|
||||
use anyhow::ensure;
|
||||
use akode_message_board::BoardReadView;
|
||||
use akode_message_board::PageRequest;
|
||||
use akode_protocol::SessionId;
|
||||
@@ -12,6 +11,7 @@ use akode_protocol::ThreadId;
|
||||
use akode_protocol::models::ResponseItem;
|
||||
use akode_protocol::protocol::HistoryPosition;
|
||||
use akode_protocol::protocol::TruncationPolicy;
|
||||
use anyhow::ensure;
|
||||
use serde::Deserialize;
|
||||
use serde::Serialize;
|
||||
use serde_json::value::RawValue;
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
//! Captures original evidence after an in-memory source cursor, without backfilling.
|
||||
//! A capture has a fixed end; consumers acknowledge records only after their writes succeed.
|
||||
|
||||
use anyhow::ensure;
|
||||
use akode_history::CodexHarnessMetadata;
|
||||
use akode_history::ResponseItemEnvelope;
|
||||
use akode_history::RetainedContextEvent;
|
||||
@@ -14,6 +13,7 @@ use akode_protocol::protocol::HistoryPosition;
|
||||
use akode_thread_store::OriginalHistoryRequest;
|
||||
use akode_thread_store::ThreadStore;
|
||||
use akode_utils_string::to_json_string_bounded;
|
||||
use anyhow::ensure;
|
||||
use serde::Deserialize;
|
||||
use serde::Serialize;
|
||||
use std::sync::Arc;
|
||||
|
||||
@@ -8,7 +8,6 @@ use crate::OriginalEvidence;
|
||||
use crate::sampling::GuardianOperation;
|
||||
use crate::sampling::HousekeeperResult;
|
||||
use crate::sampling::sample;
|
||||
use anyhow::ensure;
|
||||
use akode_guardian_reviewer::ReviewDeadline;
|
||||
use akode_guardian_reviewer::ReviewerRuntime;
|
||||
use akode_guardian_reviewer::SessionDisposition;
|
||||
@@ -24,6 +23,7 @@ use akode_protocol::SessionId;
|
||||
use akode_protocol::ThreadId;
|
||||
use akode_protocol::protocol::TruncationPolicy;
|
||||
use akode_utils_string::to_json_string_bounded;
|
||||
use anyhow::ensure;
|
||||
use serde::Deserialize;
|
||||
use serde::Serialize;
|
||||
use serde_json::json;
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
//! Read-only reviewer tools bound to one captured Guardian board.
|
||||
use crate::GUARDIAN_BOARD_NAMESPACE;
|
||||
use anyhow::ensure;
|
||||
use akode_extension_api::ExtensionData;
|
||||
use akode_extension_api::ExtensionRegistryBuilder;
|
||||
use akode_extension_api::ToolContributor;
|
||||
@@ -10,6 +9,7 @@ use akode_protocol::AgentPath;
|
||||
use akode_protocol::ThreadId;
|
||||
use akode_tools::ToolCall;
|
||||
use akode_tools::ToolExecutor;
|
||||
use anyhow::ensure;
|
||||
use std::sync::Arc;
|
||||
|
||||
/// Host-supplied review binding. Replace only between serialized reviews, under
|
||||
|
||||
@@ -5,7 +5,6 @@ use crate::GUARDIAN_BOARD_NAMESPACE;
|
||||
use crate::OperationResult;
|
||||
use crate::sampling::GuardianOperation;
|
||||
use crate::sampling::sample;
|
||||
use anyhow::ensure;
|
||||
use akode_guardian_reviewer::ReviewDeadline;
|
||||
use akode_guardian_reviewer::ReviewerRuntime;
|
||||
use akode_guardian_reviewer::SessionDisposition;
|
||||
@@ -19,6 +18,7 @@ use akode_protocol::ThreadId;
|
||||
use akode_protocol::protocol::TruncationPolicy;
|
||||
use akode_tools::ToolCall;
|
||||
use akode_tools::ToolExecutor;
|
||||
use anyhow::ensure;
|
||||
use serde::Deserialize;
|
||||
use serde::Serialize;
|
||||
use serde_json::json;
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
use crate::evidence_board::EvidenceBoard;
|
||||
use crate::evidence_board::routed_original;
|
||||
use anyhow::Context;
|
||||
use akode_guardian_v3::DeliveryPlan;
|
||||
use akode_guardian_v3::DeliveryState;
|
||||
use akode_message_board::AgentMessageBoard;
|
||||
@@ -11,6 +10,7 @@ use akode_protocol::ThreadId;
|
||||
use akode_protocol::models::ResponseItem;
|
||||
use akode_protocol::protocol::HistoryPosition;
|
||||
use akode_protocol::protocol::TruncationPolicy;
|
||||
use anyhow::Context;
|
||||
use pretty_assertions::assert_eq;
|
||||
use serde_json::Value;
|
||||
use serde_json::json;
|
||||
|
||||
@@ -14,4 +14,3 @@ pub use plugin_contributor::install_plugin_providers;
|
||||
pub use plugin_contributor::install_plugins;
|
||||
pub use plugin_contributor_state::PluginsThreadState;
|
||||
pub use plugin_providers::PluginProviders;
|
||||
|
||||
|
||||
@@ -73,7 +73,6 @@ impl PluginContributorState {
|
||||
self.executor_catalog = None;
|
||||
self.executor_snapshots.clear();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
pub(crate) struct CachedSelectedRoot {
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
use anyhow::Context;
|
||||
use akode_config::AppToolApproval;
|
||||
use akode_config::McpServerToolConfig;
|
||||
use akode_config::test_support::ManagedConfigFixture;
|
||||
@@ -27,6 +26,7 @@ use akode_protocol::capabilities::SelectedCapabilityRoot;
|
||||
use akode_protocol::config_types::WindowsSandboxLevel;
|
||||
use akode_protocol::models::PermissionProfileSnapshot;
|
||||
use akode_utils_path_uri::PathUri;
|
||||
use anyhow::Context;
|
||||
use core_test_support::mcp_test_server::McpTestServer;
|
||||
use core_test_support::mcp_test_server::recorded_mcp_tool_calls;
|
||||
use core_test_support::responses::ev_assistant_message;
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
//! Covers opt-in file copying, argument validation, and independent endpoint permissions.
|
||||
|
||||
use anyhow::Context;
|
||||
use anyhow::Result;
|
||||
use akode_core::TurnInputRequest;
|
||||
use akode_exec_server::ReadFileOptions;
|
||||
use akode_extension_api::ExtensionRegistryBuilder;
|
||||
@@ -12,6 +10,8 @@ use akode_protocol::protocol::Op;
|
||||
use akode_protocol::user_input::UserInput;
|
||||
use akode_utils_path_uri::PathConvention;
|
||||
use akode_utils_path_uri::PathUri;
|
||||
use anyhow::Context;
|
||||
use anyhow::Result;
|
||||
use core_test_support::responses::ev_assistant_message;
|
||||
use core_test_support::responses::ev_completed;
|
||||
use core_test_support::responses::ev_function_call_with_namespace;
|
||||
|
||||
@@ -9,7 +9,6 @@ use std::sync::atomic::AtomicBool;
|
||||
use std::sync::atomic::Ordering;
|
||||
use std::time::Duration;
|
||||
|
||||
use anyhow::Context;
|
||||
use akode_core::NotSubmittedReason;
|
||||
use akode_core::StartIfIdleSubmission;
|
||||
use akode_core::StartThreadOptions;
|
||||
@@ -45,6 +44,7 @@ use akode_thread_store::LocalQueueStore;
|
||||
use akode_thread_store::QueueStore;
|
||||
use akode_thread_store::ThreadStoreError;
|
||||
use akode_utils_absolute_path::test_support::PathExt;
|
||||
use anyhow::Context;
|
||||
use core_test_support::hooks::trust_discovered_hooks;
|
||||
use core_test_support::responses;
|
||||
use core_test_support::responses::start_mock_server;
|
||||
|
||||
@@ -40,12 +40,9 @@ impl From<String> for SkillLocator {
|
||||
return None;
|
||||
}
|
||||
index.parse::<usize>().ok()?;
|
||||
[
|
||||
SkillSourceKind::Executor,
|
||||
SkillSourceKind::Host,
|
||||
]
|
||||
.into_iter()
|
||||
.find(|source| alias_prefix(source) == Some(prefix))
|
||||
[SkillSourceKind::Executor, SkillSourceKind::Host]
|
||||
.into_iter()
|
||||
.find(|source| alias_prefix(source) == Some(prefix))
|
||||
});
|
||||
Self {
|
||||
value,
|
||||
|
||||
@@ -27,7 +27,11 @@ fn update_spends_budget_only_on_accepted_rows_and_their_new_roots() {
|
||||
"e0",
|
||||
"skill://writing",
|
||||
);
|
||||
let docs = skill("- docs: (executor package: e0/docs)", "e0", "skill://writing");
|
||||
let docs = skill(
|
||||
"- docs: (executor package: e0/docs)",
|
||||
"e0",
|
||||
"skill://writing",
|
||||
);
|
||||
let expected = "\n## Selected-environment skills update\n### Skill roots\nThese mappings replace earlier mappings for the same aliases.\n- `e0` = `skill://writing`\n### Added or updated skills:\n- release-notes: (executor package: e0/notes)\n- docs: (executor package: e0/docs)\n";
|
||||
let mut remaining = SkillMetadataBudget::Characters(expected.chars().count());
|
||||
let mut snapshot = CatalogSnapshot::default();
|
||||
@@ -37,7 +41,10 @@ fn update_spends_budget_only_on_accepted_rows_and_their_new_roots() {
|
||||
assert!(draft.try_append_skill(¬es, &mut snapshot, &mut remaining));
|
||||
assert!(draft.try_append_skill(&docs, &mut snapshot, &mut remaining));
|
||||
|
||||
assert_eq!(draft.into_body("Selected-environment").as_deref(), Some(expected));
|
||||
assert_eq!(
|
||||
draft.into_body("Selected-environment").as_deref(),
|
||||
Some(expected)
|
||||
);
|
||||
assert_eq!(
|
||||
snapshot.roots,
|
||||
BTreeMap::from([("e0".into(), "skill://writing".into())])
|
||||
|
||||
@@ -8,9 +8,9 @@ mod multi_query_lexical;
|
||||
mod routing_card_lexical;
|
||||
mod rrf_lexical_char;
|
||||
mod weighted_lexical;
|
||||
use akode_skills::SkillDependencies;
|
||||
pub(crate) use character_ngram::CharacterNgramSkillSelector;
|
||||
pub(crate) use character_routing_card::CharacterRoutingCardSkillSelector;
|
||||
use akode_skills::SkillDependencies;
|
||||
pub(crate) use fielded_bm25::FieldedBm25SkillSelector;
|
||||
pub(crate) use lru::LruSkillSelector;
|
||||
pub(crate) use lru_plus_character_routing::LruPlusCharacterRoutingSkillSelector;
|
||||
|
||||
@@ -385,9 +385,9 @@ where
|
||||
let mut fragments: Vec<Box<dyn ContextualUserFragment + Send>> = Vec::new();
|
||||
if config.include_instructions && !host_catalog_in_world_state {
|
||||
let mut turn_catalog = catalog.clone();
|
||||
turn_catalog.entries.retain(|entry| {
|
||||
entry.authority.kind != SkillSourceKind::Executor
|
||||
});
|
||||
turn_catalog
|
||||
.entries
|
||||
.retain(|entry| entry.authority.kind != SkillSourceKind::Executor);
|
||||
let model_info = thread_store.get::<ModelInfo>();
|
||||
let include_usage = model_info
|
||||
.as_deref()
|
||||
|
||||
@@ -625,8 +625,8 @@ pub(crate) fn render_prepared_skill_catalogs(
|
||||
);
|
||||
|
||||
for candidate in [host_only_aliases, executor_only_aliases, all_source_aliases]
|
||||
.into_iter()
|
||||
.flatten()
|
||||
.into_iter()
|
||||
.flatten()
|
||||
{
|
||||
if combined_render_is_better(
|
||||
&candidate,
|
||||
|
||||
@@ -797,10 +797,7 @@ fn mixed_catalogs_alias_all_skill_sources_under_budget_pressure() {
|
||||
.any(|line| line.contains("(file: r0/host-0/SKILL.md)"))
|
||||
);
|
||||
assert_eq!(
|
||||
(
|
||||
executor.report.included_count,
|
||||
host.report.included_count,
|
||||
),
|
||||
(executor.report.included_count, host.report.included_count,),
|
||||
(3, 3)
|
||||
);
|
||||
}
|
||||
|
||||
@@ -124,10 +124,7 @@ async fn turn_input_and_history_advance_while_ranking_is_blocked()
|
||||
catalog: thread_store
|
||||
.get::<SkillsThreadState>()
|
||||
.unwrap()
|
||||
.prepare_step_catalog(
|
||||
SkillCatalog::default(),
|
||||
/*discovery_v2*/ false,
|
||||
),
|
||||
.prepare_step_catalog(SkillCatalog::default(), /*discovery_v2*/ false),
|
||||
host_catalog: Some(host_catalog),
|
||||
config: config.clone(),
|
||||
});
|
||||
|
||||
@@ -6,7 +6,6 @@ use std::sync::Mutex;
|
||||
use std::sync::atomic::AtomicUsize;
|
||||
use std::sync::atomic::Ordering;
|
||||
|
||||
use assert_matches::assert_matches;
|
||||
use akode_attachment_store::InlineAttachmentStore;
|
||||
use akode_config::ConfigLayerEntry;
|
||||
use akode_config::ConfigLayerSource;
|
||||
@@ -91,6 +90,7 @@ use akode_skills_extension::provider::SkillReadRequest;
|
||||
use akode_skills_extension::provider::SkillSearchRequest;
|
||||
use akode_utils_absolute_path::AbsolutePathBuf;
|
||||
use akode_utils_path_uri::PathUri;
|
||||
use assert_matches::assert_matches;
|
||||
use opentelemetry_sdk::metrics::InMemoryMetricExporter;
|
||||
use opentelemetry_sdk::metrics::data::AggregatedMetrics;
|
||||
use opentelemetry_sdk::metrics::data::MetricData;
|
||||
@@ -791,8 +791,8 @@ async fn executor_and_host_share_catalog_world_state_flow() -> TestResult {
|
||||
|
||||
let expected_metrics = ["executor_world_state", "host_world_state"]
|
||||
.into_iter()
|
||||
.flat_map(|surface| expected_catalog_metric_samples(surface, /*count*/ 1))
|
||||
.collect::<Vec<_>>();
|
||||
.flat_map(|surface| expected_catalog_metric_samples(surface, /*count*/ 1))
|
||||
.collect::<Vec<_>>();
|
||||
assert_eq!(metrics.samples(), expected_metrics);
|
||||
|
||||
Ok(())
|
||||
@@ -1840,17 +1840,16 @@ async fn default_context_truncates_catalog_descriptions() -> TestResult {
|
||||
entry
|
||||
})
|
||||
.collect();
|
||||
let providers = SkillProviders::new()
|
||||
.with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let providers = SkillProviders::new().with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let mut builder = ExtensionRegistryBuilder::new();
|
||||
install_with_providers(&mut builder, providers, skills_extension_config);
|
||||
let registry = builder.build();
|
||||
@@ -1902,17 +1901,16 @@ async fn extreme_budget_pressure_removes_descriptions_before_omitting_entries()
|
||||
entry
|
||||
})
|
||||
.collect();
|
||||
let providers = SkillProviders::new()
|
||||
.with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let providers = SkillProviders::new().with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let (event_tx, event_rx) = std::sync::mpsc::channel();
|
||||
let mut builder =
|
||||
ExtensionRegistryBuilder::with_event_sink(Arc::new(ChannelEventSink(event_tx)));
|
||||
@@ -2599,17 +2597,16 @@ async fn model_context_window_scales_executor_catalog() -> TestResult {
|
||||
)
|
||||
})
|
||||
.collect();
|
||||
let providers =
|
||||
SkillProviders::new().with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let providers = SkillProviders::new().with_executor_provider(Arc::new(StaticSkillProvider {
|
||||
catalog: SkillCatalog {
|
||||
is_partial: false,
|
||||
entries: executor_entries,
|
||||
warnings: Vec::new(),
|
||||
},
|
||||
read_requests: Arc::new(Mutex::new(Vec::new())),
|
||||
list_calls: None,
|
||||
fail_first_list: false,
|
||||
}));
|
||||
let (event_tx, event_rx) = std::sync::mpsc::channel();
|
||||
let mut builder =
|
||||
ExtensionRegistryBuilder::with_event_sink(Arc::new(ChannelEventSink(event_tx)));
|
||||
|
||||
@@ -322,7 +322,8 @@ async fn v2_disabled_remote_plugin_blocks_executor_read_route() -> TestResult {
|
||||
#[tokio::test]
|
||||
async fn v1_reads_preserve_response_shape_without_installations_tool() -> TestResult {
|
||||
let executor = installed_skill("first", "work")?;
|
||||
let mut disabled = MergeHarness::new(provider(vec![executor.clone()]), default_config()).await?;
|
||||
let mut disabled =
|
||||
MergeHarness::new(provider(vec![executor.clone()]), default_config()).await?;
|
||||
disabled.snapshots = None;
|
||||
assert_eq!(
|
||||
disabled
|
||||
@@ -544,4 +545,3 @@ async fn v1_retains_legacy_plugin_disablement() -> TestResult {
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -103,9 +103,6 @@ async fn config_reload_during_preparation_applies_to_next_step() -> TestResult {
|
||||
}
|
||||
);
|
||||
}
|
||||
assert_eq!(
|
||||
*executor.queries.lock().unwrap(),
|
||||
vec![true, false]
|
||||
);
|
||||
assert_eq!(*executor.queries.lock().unwrap(), vec![true, false]);
|
||||
Ok(())
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
use akode_api::ReqwestTransport;
|
||||
use akode_api::SearchClient;
|
||||
use akode_api::SearchCommands;
|
||||
|
||||
Reference in New Issue
Block a user