You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
---------------------------------------------------------------------------
NameError Traceback (most recent call last)
Cell In[9], line 92
89 if END in step:
90 results = step
---> 92 print(results)
NameError: name 'results' is not defined
Description
I am trying to go through the Storm tutorial and the END is not being run. I verified the conditions were satisfied and threw END up front but still couldn't catch the condition. It is processing through the graph according to LangSmith.
This proof of concept shows that although the endpoint is set in the Graph, it's not being reached when specifically set with set_finish_point
Ah I think this is caused by removing the __end__ from the stream outputs by default in a recent change
hinthornw
changed the title
StateGraph.set_finish_point not terminating on Storm example
Storm example contains outdated check for END in stream output
Apr 29, 2024
This worked for me the tutorials will need to be updated to reflect this change. Is there a way to create the end or that that no longer best practice?
Do you want just the update returned in that last step?
You can just remember the last value in the loop:
last_update = None
for event in graph.stream(..., stream_mode="updates'):
last_update = event
Checked other resources
Example Code
Error Message and Stack Trace (if applicable)
Description
I am trying to go through the Storm tutorial and the END is not being run. I verified the conditions were satisfied and threw END up front but still couldn't catch the condition. It is processing through the graph according to LangSmith.
This proof of concept shows that although the endpoint is set in the Graph, it's not being reached when specifically set with
set_finish_point
System Info
langchain==0.1.16
langchain-anthropic==0.1.11
langchain-community==0.0.34
langchain-core==0.1.46
langchain-fireworks==0.1.2
langchain-openai==0.1.4
langchain-text-splitters==0.0.1
langchainhub==0.1.15
The text was updated successfully, but these errors were encountered: