Partial deploy failure loses harness state — can create duplicate resources
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 72/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- typescript
Hướng nghiên cứu
Bắt đầu với HarnessDeployer.deploy() và actions.ts quanh các dòng 531, 541 và 584, theo dõi cách deployedHarnesses và writeDeployedState() được sử dụng khi xảy ra lỗi. Xác nhận rằng một deploy thất bại vẫn lưu trạng thái của harness A đã triển khai thành công trước khi return, để deploy tiếp theo có thể cập nhật nó thay vì tạo một resource trùng lặp.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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.
- Ngôn ngữ chính
- TypeScript
- Star
- 291
- Fork
- 96
- Merge trung bình
- 20 giờ 50 phút
- Pull request đã merge (30 ngày)
- 214
Chuẩn bị môi trường
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của aws/agentcore-cli
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
aws/agentcore-cli#2395 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
aws/agentcore-cli#2392 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
aws/agentcore-cli#2267 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
aws/agentcore-cli#2258 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
aws/agentcore-cli#2176 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của aws/agentcore-cli
Issue tương tự
-
ADD openalgoĐang mởtemplate
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Maintainer thường phản hồi trong vòng 1 ngày
-
factory-active factory-automatic task-bug-reproduction-success task-identify-harness-labels-done task-identify-issue-type-done
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 90/100
vercel/ai#21528 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug Needs: Triage :mag:
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
microsoft/fluentui-contrib#671 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
sveltejs/acorn-typescript#150 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100