Skip to content

Commit

Permalink
Update graph.py
Browse files Browse the repository at this point in the history
  • Loading branch information
nfcampos committed Sep 19, 2024
1 parent e969345 commit ed27e54
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion libs/langgraph/langgraph/graph/graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,9 @@ def add_node(
"Node name must be provided if action is not a function"
)
if action is None:
raise RuntimeError("Expected a function or Runnable action in add_node. Received None.")
raise RuntimeError(
"Expected a function or Runnable action in add_node. Received None."
)
if node in self.nodes:
raise ValueError(f"Node `{node}` already present.")
if node == END or node == START:
Expand Down

0 comments on commit ed27e54

Please sign in to comment.