Partial deploy failure loses harness state — can create duplicate resources
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 72/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 冷清
- 技术栈
- typescript
调研方向
从 HarnessDeployer.deploy() 和 actions.ts 第 531、541、584 行附近开始,跟踪失败时 deployedHarnesses 和 writeDeployedState() 的使用方式。确认失败的 deploy 在返回前会持久化成功的 harness A 状态,以便下一次 deploy 可以更新它,而不是创建重复资源。
由索引模型根据 Issue 内容生成。
描述
Problem
If deploying harness B fails after harness A succeeds, the partial state (containing harness A's new ID) is never persisted to disk.
Flow:
HarnessDeployer.deploy()returns{ success: false, state: resultState }—resultStatecontains harness A's IDactions.ts:531extracts the state intodeployedHarnessesactions.ts:541returns early with an error — beforewriteDeployedState()at line 584
On next deploy attempt, the state file doesn't know harness A exists. The deployer takes the CREATE path (createHarness with clientToken: randomUUID()), producing a duplicate cloud resource. The previous harness A is orphaned.
Expected behavior
Partial state should be persisted even on failure, so the next deploy attempt can UPDATE existing harnesses rather than re-creating them.
Possible fix
Write deployed state before the early return at line 541:
if (harnessDeployError) {
// Persist partial state so successfully-created harnesses aren't orphaned
await configIO.writeDeployedState(buildDeployedState(...));
return { success: false, error: harnessDeployError };
}
Context
Found during review of #1341.
- 主要语言
- TypeScript
- 星标
- 291
- 派生
- 96
- 平均合并
- 20 小时 50 分钟
- 30 天内合并 PR
- 214
环境准备
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
aws/agentcore-cli 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 70/100
aws/agentcore-cli#2395 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
aws/agentcore-cli#2392 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
aws/agentcore-cli#2267 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
aws/agentcore-cli#2258 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
aws/agentcore-cli#2176 ·
维护者通常 1 天内回复
查看 aws/agentcore-cli 的全部 Issue
相似的 Issue
-
module-request
难度 2/5 1-3 小时 新手友好度 68/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 90/100
appandflow/stim#1604 · 1 条评论 ·
维护者通常 1 天内回复
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
难度 1/5 1 小时以内 新手友好度 92/100
lingdojo/kana-dojo#31060 · 1 条评论 · 5 个 reaction ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 90/100
paperclipai/paperclip#14173 ·
维护者通常 1 天内回复
-
needs-triage
难度 2/5 1-3 小时 新手友好度 85/100
维护者通常 1 天内回复