Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Approval-gated action interrupted before its result is saved can never be retried

未关闭
#134 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 2 天内回复

@DerekChia 已经在做这个了。

开始于 2026年10月10日。

  • #135 来自 @DerekChia —— 未关闭
  • #141 来自 @charan-rathore —— 已关闭,未合并

评估

难度
4/5
预计耗时
3-5 天
新手友好度
68/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃

调研方向

Start with the action receipt and the claimAction/finishAction flow around the mcp_actions table and the POST /api/conversations/thread/connection-actions endpoint. Also trace the approval action card’s polling and retry controls, using the 60-second ConnectionService timeout as the stale-run threshold. Done means an interrupted result-less run can be reclaimed only by its original approval, fresh claims still receive 409, saved results remain protected, and the UI exposes a successful retry.

由索引模型根据 Issue 内容生成。

描述

Problem

If the server stops between claiming an approval-gated MCP action (claimAction) and saving its result (finishAction), that (threadId, toolCallId) is bricked: every retry returns 409 This action is already running. forever, because mcp_actions rows have no expiry and there is no code path that clears a result-less running row.

Worse, the owner has no way to retry from the UI: the action card polls the receipt every 2s, sees status: running, shows "Running / This action is still running on the server.", and hides the Approve buttons while running is true. The card sits on "Running" forever with no affordance.

Reproduction

  1. Start OpenDots (local npm run dev, Node v22.23.1) with a Dot that has an MCP connection with a gated (non-read-only) tool.
  2. Have the Dot call the gated tool so the owner gets an approval card.
  3. Approve it, and kill the server process after the claim INSERT but before the result UPDATE lands (equivalently: INSERT INTO mcp_actions(threadId,toolCallId,connectionId,tool,status,result,createdAt,approvalId) VALUES('thread','tc1','c','tool','running',NULL,<now>,'<approvalId>');).
  4. Restart the server and open the conversation.
  5. The card shows "Running" forever; approving/refreshing never completes. POST /api/conversations/thread/connection-actions with the same approval returns 409 {"error":"This action is already running."} on every attempt, until the approval itself expires an hour later.

Expected: after the in-flight run is demonstrably gone, the receipt should surface the interruption and the same approval should be able to run the stored request again (the request is already bound to its exact connection/tool/arguments, and only that approval may reclaim it).

Actual: misleading "already running" 409 with no self-healing and no owner retry path.

Notes

  • MCP tool calls are bounded to 60s (ConnectionService timeout), so a result-less claim older than a few minutes cannot belong to a live run.
  • The fix must preserve the double-claim guard: a fresh running row must still 409 (double click / retried request must not execute twice), a saved result must still be returned only to its own approval, and a different approval must never steal the claim.
主要语言
TypeScript
星标
4.8k
派生
690
平均合并
1 天 15 小时
30 天内合并 PR
43

环境准备

  • 提供 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

CopilotKit/OpenDots 的其他 Issue

查看 CopilotKit/OpenDots 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。