Skip to content

Commit faacce2

Browse files
committed
style: improve code formatting and readability across multiple files
1 parent d45cd1e commit faacce2

File tree

5 files changed

+25
-29
lines changed

5 files changed

+25
-29
lines changed

cli/src/daemon/client.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,7 @@ use aegis_orchestrator_sdk::AgentManifest;
1818
#[derive(Deserialize)]
1919
#[serde(untagged)]
2020
enum WorkflowListResponse {
21-
Wrapped {
22-
workflows: Vec<serde_json::Value>,
23-
},
21+
Wrapped { workflows: Vec<serde_json::Value> },
2422
Bare(Vec<serde_json::Value>),
2523
}
2624

cli/src/daemon/server.rs

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,8 @@ pub async fn start_daemon(config_path: Option<PathBuf>, port: u16) -> Result<()>
122122
.context("Configuration validation failed")?;
123123

124124
if let Some(smcp_gateway) = &config.spec.smcp_gateway {
125-
let resolved_url = resolve_env_value(&smcp_gateway.url)
126-
.unwrap_or_else(|_| smcp_gateway.url.clone());
125+
let resolved_url =
126+
resolve_env_value(&smcp_gateway.url).unwrap_or_else(|_| smcp_gateway.url.clone());
127127
tracing::info!(
128128
"Configured SMCP tooling gateway URL from node config: {}",
129129
resolved_url
@@ -1042,14 +1042,9 @@ pub async fn start_daemon(config_path: Option<PathBuf>, port: u16) -> Result<()>
10421042
Arc::new(
10431043
aegis_orchestrator_core::infrastructure::web_tools::ReqwestWebToolAdapter::new(),
10441044
),
1045-
config
1046-
.spec
1047-
.smcp_gateway
1048-
.as_ref()
1049-
.map(|gateway| {
1050-
resolve_env_value(&gateway.url)
1051-
.unwrap_or_else(|_| gateway.url.clone())
1052-
}),
1045+
config.spec.smcp_gateway.as_ref().map(|gateway| {
1046+
resolve_env_value(&gateway.url).unwrap_or_else(|_| gateway.url.clone())
1047+
}),
10531048
)
10541049
.with_workflow_authoring(
10551050
register_workflow_use_case.clone(),

orchestrator/core/src/application/tool_invocation_service.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,9 @@ impl ToolInvocationService {
130130
))?;
131131

132132
// 2. Middleware verifies signature and evaluates against SecurityContext
133-
let args = self.smcp_middleware.verify_and_unwrap(&mut session, envelope)?;
133+
let args = self
134+
.smcp_middleware
135+
.verify_and_unwrap(&mut session, envelope)?;
134136
let tool_name = envelope
135137
.extract_tool_name()
136138
.ok_or(SmcpSessionError::MalformedPayload(

orchestrator/core/src/domain/smcp_session.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,10 @@ impl SmcpSession {
241241
/// This is the **single enforcement point** for all SMCP policy checks. Every
242242
/// tool call from any agent must pass through this method before being forwarded
243243
/// to the MCP server. See ADR-035 §4 (Enforcement Architecture).
244-
pub fn evaluate_call(&mut self, envelope: &impl EnvelopeVerifier) -> Result<(), SmcpSessionError> {
244+
pub fn evaluate_call(
245+
&mut self,
246+
envelope: &impl EnvelopeVerifier,
247+
) -> Result<(), SmcpSessionError> {
245248
let now = Utc::now();
246249

247250
// 1. Check session is active

orchestrator/core/src/infrastructure/repositories/postgres_execution.rs

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -303,13 +303,12 @@ impl ExecutionRepository for PostgresExecutionRepository {
303303
))),
304304
}?;
305305

306-
let input: ExecutionInput =
307-
serde_json::from_value(input_val).map_err(|e| {
308-
RepositoryError::Serialization(format!(
309-
"Failed to deserialize execution input: {}",
310-
e
311-
))
312-
})?;
306+
let input: ExecutionInput = serde_json::from_value(input_val).map_err(|e| {
307+
RepositoryError::Serialization(format!(
308+
"Failed to deserialize execution input: {}",
309+
e
310+
))
311+
})?;
313312
let iterations: Vec<Iteration> =
314313
serde_json::from_value(iterations_val).map_err(|e| {
315314
RepositoryError::Serialization(format!(
@@ -411,13 +410,12 @@ impl ExecutionRepository for PostgresExecutionRepository {
411410
))),
412411
}?;
413412

414-
let input: ExecutionInput =
415-
serde_json::from_value(input_val).map_err(|e| {
416-
RepositoryError::Serialization(format!(
417-
"Failed to deserialize execution input: {}",
418-
e
419-
))
420-
})?;
413+
let input: ExecutionInput = serde_json::from_value(input_val).map_err(|e| {
414+
RepositoryError::Serialization(format!(
415+
"Failed to deserialize execution input: {}",
416+
e
417+
))
418+
})?;
421419
let iterations: Vec<Iteration> =
422420
serde_json::from_value(iterations_val).map_err(|e| {
423421
RepositoryError::Serialization(format!(

0 commit comments

Comments
 (0)