Skip to content

[BUG] 17 open Flow bugs in checkpoint restore, from_pending resume, human feedback and concurrent listeners, 16 with a community fix PR #9290

Open

Description

Description

João Moura (@joaomdmoura) Lorenze Jay (@lorenzejay) A status summary of 17 Flow bugs we reported, none of which has had a maintainer response yet. Resuming from a checkpoint or with from_pending loses routes, joins and state or runs completed methods again; pausing for human feedback in one of two concurrent listeners drops the other; automatic checkpoints fail or crash when listeners run concurrently. All but #8974 already have an open community fix PR.

Steps to Reproduce

Each issue listed below has its own self-contained reproduction.

Expected behavior

As stated in each issue.

Screenshots/Code snippets

See each issue's reproduction.

Operating System

Ubuntu 22.04

Python Version

3.12

crewAI Version

1.15.28 to 1.15.35 (the version is in each issue); multi-PR checks on main (1.15.39)

crewAI Tools Version

not used

Virtual Environment

Venv

Evidence

Where an issue has more than one PR, we installed crewai and crewai-core from each PR's branch and ran the issue's reproduction (the reproductions only, not the full test suite); the race in #8749 ran 10 times per branch (9 of 10 failures on main, 0 of 10 with each PR). #8440 no longer reproduced on main in 10 runs, so it may already be fixed there.

Issue What goes wrong Fix PR
#8437 Resuming a flow from a checkpoint stops at a completed router: the listeners of its route never run fixes it: #8446; does not fix it: #8928
#8438 A flow resumed from a checkpoint writes checkpoints of a blank flow, so a second resume starts over fixes it: #8448; does not fix it: #8459
#8439 Pausing for human feedback in one of two concurrent listeners loses the other listener and their and_ join fixes it: #8454; does not fix it: #8459, #8461, #9246
#8440 An automatic checkpoint taken while an async listener writes the flow state fails the flow with PanicException does not reproduce on current main (0 of 10 runs; 30 of 36 on 1.15.28, where #8447 fixed it: 0 of 30) - possibly fixed on main already
#8441 A flow resumed with from_pending forgets the methods completed before the pause, so a later checkpoint restore runs them again fixes it: #8459, #8461
#8624 After an agent with a tool runs in a flow, every automatic checkpoint fails, so a resume runs the agent again open: #8625
#8688 After a flow resumes with from_pending, the checkpoints of a later flow also hold it, so from_checkpoint restores the earlier flow instead fixes it: #8693, #8694
#8697 Two agents set up at the same time can fail with "RuntimeError: dictionary changed size during iteration" while CrewAI builds a flow definition open: #8700
#8749 A flow fails with "RuntimeError: dictionary changed size during iteration" when a method starts while a plain listener adds to the state fixes it: #8750, #8835, #8970
#8836 After an agent's tool call raises, every automatic checkpoint fails ("Unable to serialize unknown type: ValueError"), so a resume runs the agent again fixes it: #8837, #8839
#8840 When a listener pauses for human feedback, the listeners of a router triggered by the same method never run, even after the flow resumes open: #8841
#8927 A flow resumed from a checkpoint leaves a loop early: methods that ran after the resume are skipped as already completed open: #8928
#8960 A flow kicked off with kickoff_async under asyncio.run, or with stream=True, stays in the runtime state, so a later flow's checkpoints restore the earlier flow open: #8964
#8971 A flow with a custom FlowPersistence cannot be restored from a checkpoint: "Can't instantiate abstract class FlowPersistence" open: #8975
#8974 After a checkpoint restore, a listener receives its trigger's Pydantic output as a dict, so @human_feedback listeners lose .feedback no PR yet
#8980 A flow resumed from a checkpoint calls the listener of a completed method with None instead of that method's output open: #8998
#9022 Automatic checkpoints are written in parallel and out of order, so the latest checkpoint can hold an older state and resuming from it reruns completed methods open: #9023

Possible Solution

The PRs marked "fixes it" above.

Additional context

We are glad to help verify or adjust any of these fixes.

Activity

  1. added
    bug
    on Nov 9, 2026
  2. yifanxiong272 commented on Nov 15, 2026

    @yifanxiong272
    Author

    Vidit Ostwal (@Vidit-Ostwal) João Moura (@joaomdmoura) Lorenze Jay (@lorenzejay) A short follow-up on the 17 Flow issues above. None has had a maintainer response yet, and the stale workflow will mark the oldest four (#8437 to #8440, last active on October 23) on November 22 and close them on November 27.

    Seven of them only need a review: when we ran each issue's reproduction against these community PRs' branches on November 9, the PR made it pass.

    All 17 reproductions still fail on main as of November 13. The race in #8440 is rare with the default thread switch interval, but with sys.setswitchinterval(1e-6) its PanicException shows in 20 of 20 runs on main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions