From 1e03390491461a8cca6d232e7be43478b43f17cf Mon Sep 17 00:00:00 2001 From: Claude-51124 Date: Wed, 4 Feb 2026 17:56:08 +0900 Subject: [PATCH] =?UTF-8?q?docs:=20260204=20=EC=BD=9C=EB=93=9C=EB=A9=94?= =?UTF-8?q?=EC=9D=BC=20=ED=99=95=EC=9D=B8=20=EC=95=84=EB=8B=88=EC=98=A4-?= =?UTF-8?q?=EC=98=88=20=EC=88=9C=EC=84=9C=20=EB=A6=AC=EC=8A=A4=ED=8A=B8=20?= =?UTF-8?q?=EB=AF=B8=EB=93=B1=EB=A1=9D=20=ED=8A=B8=EB=9F=AC=EB=B8=94?= =?UTF-8?q?=EC=8A=88=ED=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Cursor --- ...60204_coldmail_confirm_route_after_wait.md | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 journey/troubleshooting/260204_coldmail_confirm_route_after_wait.md diff --git a/journey/troubleshooting/260204_coldmail_confirm_route_after_wait.md b/journey/troubleshooting/260204_coldmail_confirm_route_after_wait.md new file mode 100644 index 0000000..bbb1ee9 --- /dev/null +++ b/journey/troubleshooting/260204_coldmail_confirm_route_after_wait.md @@ -0,0 +1,44 @@ +# 콜드메일 확인 "아니오→예" 순서 시 리스트 미등록 수정 + +**날짜**: 2026-02-04 +**작성자**: happybell80 +**관련 파일**: `rb8001/app/services/workflows/coldmail_workflow.py` + +--- + +## 문제 상황 + +- 콜드메일 확인 메시지 2건 동시 도착 시, 1번 "아니오" → 2번 "예" 순서로 클릭하면 2번 "예"가 리스트에 반영되지 않음. +- 로그: 2번 "예" 시 `Workflow resumed and completed for {email_id}, confirmed=True`만 있고, `confirm_node`·`process_coldmail`·"리스트 등록 완료" 로그 없음. + +--- + +## 원인 + +- `route_after_wait`: `confirmed_email_id`가 없으면 무조건 `"send"` 반환. +- 1번 "아니오" 클릭 시 `confirmed_email_id` 비움 → `send` → 워크플로우 END. +- 2번 "예" 재개 시 스레드는 이미 END라 실행할 노드 없음 → `confirm_node` 미실행 → 리스트 등록 안 됨. + +--- + +## 해결 방안 + +- `coldmail_workflow.py`: `route_after_wait` 수정 + - `confirmed_email_id` 있음 → `"confirm"` + - 없고 `waiting_confirmation` 남음 → `"wait_confirmation"` (인터럽트 유지) + - 없고 `waiting_confirmation` 비었음 → `"send"` +- 위치: `route_after_wait` 함수 (L355 부근), 조건 2개 추가. + +--- + +## 구현 완료 + +- 커밋: fix(coldmail): route_after_wait에서 남은 확인건 있으면 wait_confirmation 재진입 +- rb8001 main 푸시 후 Gitea Actions 자동 배포. + +--- + +## 교훈 + +- **원인**: interrupt 재개 후 라우팅에서 "이번 응답"만 보지 말고, **남은 대기 건(`waiting_confirmation`) 존재 여부**를 반드시 조건에 포함해야 함. +- **방지**: 다중 확인 UX(아니오→예, 예→아니오 등 버튼 순서 조합)를 시나리오/테스트에 포함해 재현 후 라우팅 검증.