Skip to content

Commit 58ebb69

Browse files
committed
Raise error in case nither condition nor action provided in updating guideline
1 parent d3bab84 commit 58ebb69

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/parlant/bin/client.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2476,7 +2476,9 @@ def guideline_update(
24762476
check: bool,
24772477
connect: bool,
24782478
) -> None:
2479-
assert condition or action
2479+
if not (condition or action):
2480+
Interface.write_error("At least one of --condition or --action must be specified")
2481+
raise FastExit()
24802482

24812483
agent_id = agent_id if agent_id else Interface.get_default_agent(ctx)
24822484
assert agent_id

0 commit comments

Comments
 (0)