Skip to content

Commit 30d22f8

Browse files
committed
strip inline comments from the retry policy diff
1 parent f86b9ce commit 30d22f8

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

swarms/structs/graph_workflow.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -722,8 +722,6 @@ def __init__(
722722
self.type = type
723723
self.agent = agent
724724
self.metadata = metadata or {}
725-
# None means "use the workflow default", resolved at run time so the
726-
# default can be set after the nodes were added.
727725
self.retry = retry
728726

729727
if not self.id:
@@ -990,7 +988,6 @@ def __init__(
990988

991989
# Checkpoint configuration
992990
self.checkpoint_dir = checkpoint_dir
993-
# None means no retrying, the historical behaviour.
994991
self.retry_policy = retry_policy
995992
if on_node_failure not in (
996993
"skip_downstream",
@@ -1002,7 +999,6 @@ def __init__(
1002999
f"'propagate_error', got {on_node_failure!r}"
10031000
)
10041001
self.on_node_failure = on_node_failure
1005-
# node_id -> error, so callers need not grep outputs for '[ERROR]'.
10061002
self.failed_nodes: Dict[str, str] = {}
10071003

10081004
# Private optimization attributes
@@ -2025,8 +2021,6 @@ def _handle_node_failure(
20252021
if self.on_node_failure == "propagate_error":
20262022
return f"[ERROR] Agent {agent_name} failed: {exc}"
20272023

2028-
# skip_downstream: dependents are pruned rather than handed an error
2029-
# string that reads like an answer.
20302024
skipped.add(node_id)
20312025
logger.warning(
20322026
f"Node {node_id} failed; skipping its dependents "

0 commit comments

Comments
 (0)