Command resume with update throws, but docs show that it shouldn't. #232

Closed
opened 2026-02-15 17:17:41 -05:00 by yindo · 3 comments
Owner

Originally created by @kenshin54 on GitHub (Apr 16, 2025).

Originally assigned to: @dqbd on GitHub.

Hi there, we noticed something is broken in our graph that caused by the recent changes introduced in PR #1068.

https://github.com/langchain-ai/langgraphjs/blob/318830a6f86037ed69e34e9b0031ec89fbd725bc/libs/langgraph/src/pregel/loop.ts#L828-L832

It blocked using resume while updating the graph state. However, in the official doc of using command, there is a code example tells we can do that.

// Update the graph state and resume.
// You must provide a `resume` value if using an `interrupt`.
await graph.invoke(
  new Command({ resume: "Let's go!!!", update: { foo: "bar" } }),
  threadConfig
);

I'm wondering what's the right one?

Originally created by @kenshin54 on GitHub (Apr 16, 2025). Originally assigned to: @dqbd on GitHub. Hi there, we noticed something is broken in our graph that caused by the recent changes introduced in PR #1068. https://github.com/langchain-ai/langgraphjs/blob/318830a6f86037ed69e34e9b0031ec89fbd725bc/libs/langgraph/src/pregel/loop.ts#L828-L832 It blocked using resume while updating the graph state. However, in the [official doc](https://langchain-ai.github.io/langgraphjs/concepts/human_in_the_loop/#the-command-primitive) of using command, there is a code example tells we can do that. ```js // Update the graph state and resume. // You must provide a `resume` value if using an `interrupt`. await graph.invoke( new Command({ resume: "Let's go!!!", update: { foo: "bar" } }), threadConfig ); ``` I'm wondering what's the right one?
yindo closed this issue 2026-02-15 17:17:41 -05:00
Author
Owner

@rd-joni commented on GitHub (Apr 26, 2025):

same issue here

@rd-joni commented on GitHub (Apr 26, 2025): same issue here
Author
Owner

@benjamincburns commented on GitHub (Apr 28, 2025):

cc @dqbd

@benjamincburns commented on GitHub (Apr 28, 2025): cc @dqbd
Author
Owner

@benjamincburns commented on GitHub (May 7, 2025):

Fixed by #1146 in latest release. Thanks for reporting this, @kenshin54! (and thanks for the fix, @dqbd!)

@benjamincburns commented on GitHub (May 7, 2025): Fixed by #1146 in latest release. Thanks for reporting this, @kenshin54! (and thanks for the fix, @dqbd!)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/langgraphjs#232