fix(worker,ui): clean up three review leftovers from the list-handler run

Remove the redundant TaskUpdated broadcast in TaskRunner.ContinueAsync's
queue-claim path, consolidate InteractiveLaunchSpecService's seven
MCP_TOOL_TIMEOUT literals into one constant (fixing the merge-helper handoff
spec's stale 200000ms value), and surface OpenQuickClaudeSession's two
failure cases via ErrorReported/footer instead of a silent no-op, with a
less ambiguous icon.
This commit is contained in:
mika kuns
2026-08-06 11:31:03 +02:00
parent b66ce580de
commit b54a133c16
10 changed files with 220 additions and 17 deletions
+2 -2
View File
@@ -60,8 +60,8 @@ public sealed class ClaudeProcess : IClaudeProcess
// wait_for_task_change blocks up to TaskWaitMcpTools.MaxTimeoutSeconds (900 s) and the
// in-task AskUser tool blocks up to 3 min waiting for the user, so lift the cap well
// past the longer of the two (with margin) or that wait would be killed early. Harmless
// for every other tool. Keep in sync with InteractiveLaunchSpecService's MCP_TOOL_TIMEOUT.
psi.Environment["MCP_TOOL_TIMEOUT"] = "930000";
// for every other tool. Shares the value with InteractiveLaunchSpecService.McpToolTimeoutMs.
psi.Environment["MCP_TOOL_TIMEOUT"] = InteractiveLaunchSpecService.McpToolTimeoutMs;
using var process = new Process { StartInfo = psi };
process.Start();
@@ -27,6 +27,11 @@ namespace ClaudeDo.Worker.Runner;
// `--resume` pickup in a Windows Terminal window.
public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
{
// Claude Code caps HTTP MCP tool calls at 60s unless raised; every ConPTY spec built by this
// service lifts it well past wait_for_task_change's 900s server-side cap. Keep in sync with
// ClaudeProcess's own MCP_TOOL_TIMEOUT (same value, set independently for headless runs).
public const string McpToolTimeoutMs = "930000";
private readonly IDbContextFactory<ClaudeDoDbContext> _dbFactory;
private readonly ISessionSkillSeeder _skillSeeder;
private readonly ISessionSkillRegistry _skillRegistry;
@@ -111,7 +116,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
// it is harmless for every other tool. Keep in sync with ClaudeProcess's MCP_TOOL_TIMEOUT.
var env = new Dictionary<string, string>
{
["MCP_TOOL_TIMEOUT"] = "930000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
return new LaunchSpec(worktree.Path, resolvedClaude, args, env);
@@ -129,7 +134,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
{
["MAX_THINKING_TOKENS"] = "20000",
["CLAUDEDO_PLANNING_TOKEN"] = ctx.Token,
["MCP_TOOL_TIMEOUT"] = "930000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
return new LaunchSpec(
@@ -147,7 +152,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
var env = new Dictionary<string, string>
{
["CLAUDEDO_PLANNING_TOKEN"] = ctx.Token,
["MCP_TOOL_TIMEOUT"] = "930000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
return new LaunchSpec(
@@ -170,7 +175,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
var env = new Dictionary<string, string>
{
["MCP_TOOL_TIMEOUT"] = "930000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
// No task and no list here — the global default model's preset decides the effort.
@@ -247,7 +252,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
var env = new Dictionary<string, string>
{
["MCP_TOOL_TIMEOUT"] = "930000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
return new LaunchSpec(repoDir, resolvedClaude, args, env);
@@ -320,7 +325,7 @@ public sealed class InteractiveLaunchSpecService : IInteractiveLaunchSpecService
var env = new Dictionary<string, string>
{
["MCP_TOOL_TIMEOUT"] = "200000",
["MCP_TOOL_TIMEOUT"] = McpToolTimeoutMs,
};
return new LaunchSpec(repoDir, resolvedClaude, args, env);
-1
View File
@@ -266,7 +266,6 @@ public sealed class TaskRunner
await _broadcaster.TaskUpdated(taskId);
}
await _broadcaster.TaskStarted(slot, taskId, now);
await _broadcaster.TaskUpdated(taskId);
await _skillSeeder.SeedAsync(runDir, resolvedConfig.SkillNames, wtCtx is not null, ct);