What this thread does
Catch the expected exception inside the LangGraph task and return a value as the reporter's workaround for caught-error replay after an interrupt (roydonsequeira, langchain-ai/langgraph #9475).
Do first: move the specific ConnectionError handler into the failing @task and return the failure outcome as data; roydonsequeira says this avoids the replay mismatch because that child then completes with a saved result (#9475).
Diagnostic: resumed status and saved alert disagree
Evidence: the original reproducer and two independent contributors' local patch reports; the workaround is the reporter's statement. Not for: adding an ordinary human approval pause; see langgraph-pause-for-human-approval-interrupt-checkpointer.
Findings
- Affected versions/platform: roydonsequeira's October 28 report names LangGraph 1.2.18 and main
5a3e5dd7, plus reproductions on 0.4.8, 0.6.11, 1.0.10, 1.1.10, 1.2.0, 1.2.12 and 1.2.13. The environment is Python 3.13.1 on Windows 11, checkpoint 4.3.1, checkpoint-sqlite 3.1.2 and langchain-core 1.7.0. The author reports sync/async behavior with InMemorySaver and AsyncSqliteSaver across exit/async/sync durability modes; this does not establish every intervening release.
- Symptom: the sample task raises “status page timed out”; the entrypoint catches it, produces a down-status alert and pauses. On resume, the check succeeds with an up status, but the previously saved down alert is reused. The reporter's diagnosis is that task replay copies successful output but omits the saved child error, allowing the child to run again while dependent results remain cached (roydonsequeira, #9475).
- Independent replay investigation: AvinashKalamati, October 29, reports reproducing on main and restoring the child error when the parent did not fail. That stops the duplicate child execution in their experiment, but the saved exception is a string and becomes a generic Exception; the parent's
except ConnectionErrorthen misses it. The contributor asks for maintainer direction before a PR.
- Branch consistency matters: lucafranco1994pot-cloud, October 30, reports an experimental patch against main
8d5637b2with 27 additional cases covering replay and exception handling. Their stated requirement is preserving the parent's original exception-handling branch, not merely reducing the call count. They explicitly say no PR has been opened.
- Workaround check: after returning the expected failure as a task value, use the original sample's execution log and returned status/alert pair to check both child call count and consistency. This check is adapted from the reproducer and the second contributor's branch-consistency warning; its outcome on your workflow is untested (#9475, lucafranco1994pot-cloud).
- Release status: the official LangGraph 1.2.19 release, October 30, does not list a caught-error replay repair. The issue remains open and the cited patch reports are experiments; these sources establish no released fix.
Limits
This covers an exception caught by the entrypoint before a later interrupt, not the intended retry after an uncaught run failure. The inside-task workaround changes the result contract and needs matching consumer handling. Contributor suite outcomes are their reports, not proof for every saver or application.
Started from a post by @langchain-ai/langgraph maintainers, packaged by the editor. Original post