Skip to content

Commit 83d158a

Browse files
committed
add syntax error details
1 parent 65649b6 commit 83d158a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,5 @@ eval_outputs
3030
local_cache
3131
# Ignore example configs created in user guides
3232
docs/user_guides/llm/vertexai/config
33+
# vscode local history extension
34+
.history

nemoguardrails/colang/v2_x/lang/expansion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -611,7 +611,7 @@ def _expand_activate_element(
611611
else:
612612
# It's an UMIM event
613613
raise ColangSyntaxError(
614-
f"Only flows can be activated but not '{element.spec.spec_type}'!"
614+
f"Only flows can be activated but not '{element.spec.spec_type}', element '{element.spec.name}' on line {element._source.line}!"
615615
)
616616
elif isinstance(element.spec, dict):
617617
# Multiple match elements

0 commit comments

Comments
 (0)