You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
simlin-mcp-core: LTM diagnostics never surface (collect_all_diagnostics runs with ltm_enabled=false) #662
simlin-mcp-core collects diagnostics on a freshly-synced db with ltm_enabled=false (the default), so LTM-specific diagnostics never reach MCP callers. Call sites:
src/simlin-mcp-core/.../read_model.rs (around line 79)
src/simlin-mcp-core/.../edit_model.rs (around lines 262 and 290)
These call simlin_engine::db::collect_all_diagnostics without ever enabling LTM. As a result MCP callers see neither the auto-flip advisory ("LTM auto-switched to discovery") nor the LTM fragment-compile-failure warnings (model_ltm_fragment_diagnostics), both of which only accumulate when SourceProject::ltm_enabled is true.
This bypasses the GH #466 latch fix entirely. #466 fixed the libsimlin FFI path (simlin_project_get_errors transiently re-enables ltm_enabled for the diagnostic harvest via the LtmEnabledGuard whenever any sim on the project was created with enable_ltm=true). But simlin-mcp-core is a separate code surface -- it calls collect_all_diagnostics directly on its own synced db and never applies the #466 transient-enable, so the latch fix does not reach MCP analyze surfaces. #466 does not mention simlin-mcp-core.
Why it matters
UX / diagnostic visibility for AI-agent workflows. The MCP read_model / edit_model tools are the canonical "what's wrong with my model?" surface for agents, and they silently drop LTM advisories and fragment-failure warnings that a user who asked for LTM analysis would want to see.
Mirror the #466 approach: transiently enable ltm_enabled for the diagnostic-collection pass, gated on whether the MCP caller actually requested LTM analysis (so non-LTM callers don't pay the LTM synthesis cost).
Severity
Low-medium (UX; not a correctness bug).
Discovery context
Identified during an LTM-hardening session while tracing the #466 latch fix across all diagnostic-collection surfaces.
Activity
mcp-core: collect MCP diagnostics with LTM enabled (GH #662)