Skip to content

Commit 1486ceb

Browse files
fix(config): bind dashboard profile writes to daemon identity
Completes 087768f (config-vertical wind-down): the last two of its eight remaining hunks. handle_dashboard now takes the daemon_user_profile_id that execute_tool_dispatch already threads through ToolCallRegistryOptions (landed via 087768f + bb6f598), and the profile identity for DashboardInvocationExecutorAdapter comes from the daemon-handshake profile identity instead of the project-session store binding, which is None on the core server that answers tool calls before the session authorities mount (the 503 configuration_authority_unavailable root, DEFECT B in 087768f). TIP-UNBREAK: dispatch_groups.rs at HEAD already passes this argument, so HEAD does not compile without this commit. Hunk dispositions for the other six (verified with git log -S, ledger duplication-check honored): application_surface.rs payload arm + import landed via 3299dce; handlers/mod.rs field + Default landed via bb6f598; runtime_surface_acceptance idempotency keys landed via cd42d49. Verification queued per the single-build-runner directive. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 08fde90 commit 1486ceb

1 file changed

Lines changed: 9 additions & 5 deletions

File tree

src/mcp/tools/handlers/dashboard.rs

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -314,6 +314,7 @@ pub(super) async fn handle_dashboard(
314314
args: Value,
315315
retained_project_graph_resolver: Option<crate::mcp::server::RetainedProjectGraphResolver>,
316316
registered_project_session_db: Option<Arc<RegisteredGlobalDb>>,
317+
daemon_user_profile_id: Option<UserProfileId>,
317318
lcm_retrieval: Option<Arc<dyn SessionRetrievalServicePort>>,
318319
registered_savings_db: Option<Arc<RegisteredGlobalDb>>,
319320
automation_scheduler_reconciler: Option<AutomationSchedulerReconciler>,
@@ -403,12 +404,14 @@ pub(super) async fn handle_dashboard(
403404
})?;
404405
let dashboard_project_graph_resolver = retained_project_graph_resolver
405406
.map(crate::mcp::server::dashboard_retained_project_graph_resolver);
406-
let dashboard_profile_id = registered_project_session_db
407-
.as_ref()
408-
.map(|database| database.binding().shard_id.profile_id.clone());
407+
// The profile write resolves its configuration layer through the
408+
// profile identity the daemon handshake bound, which every
409+
// daemon-owned server carries. Reading it from the project-session
410+
// store instead withheld every profile mutation on the core server
411+
// that answers tool calls before the session authorities mount.
409412
let application_invocation_executor = application_invocation_executor
410413
.map(|executor| {
411-
DashboardInvocationExecutorAdapter::new(executor, dashboard_profile_id)
414+
DashboardInvocationExecutorAdapter::new(executor, daemon_user_profile_id)
412415
.map(|adapter| Arc::new(adapter) as Arc<dyn DashboardApplicationRuntime>)
413416
})
414417
.transpose()?;
@@ -442,7 +445,8 @@ pub(super) async fn handle_dashboard(
442445
super::dashboard_git_correlation::DashboardGitCorrelationReadAdapter::new(
443446
Arc::clone(database),
444447
),
445-
) as Arc<dyn crate::dashboard::DashboardGitCorrelationReadPortV1>
448+
)
449+
as Arc<dyn crate::dashboard::DashboardGitCorrelationReadPortV1>
446450
});
447451
crate::hooks::install_dashboard_hook_readiness_projection()?;
448452
let state = build_state_with_automation_reconciler(

0 commit comments

Comments
 (0)