Skip to content
This repository was archived by the owner on Mar 4, 2026. It is now read-only.

Commit d9b6866

Browse files
author
Valentina Bojan
committed
feat(guardrails): add optional rule description for universal rule
1 parent 5dddf46 commit d9b6866

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/uipath/core/guardrails/guardrails.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ class WordRule(BaseModel):
133133
exclude=True,
134134
description="Human-friendly description of the rule condition.",
135135
)
136-
detects_violation: Callable[[str | None], bool] = Field(
136+
detects_violation: Callable[[str], bool] = Field(
137137
exclude=True,
138138
description="Function that returns True if the string violates the rule (validation should fail).",
139139
)
@@ -171,7 +171,7 @@ class NumberRule(BaseModel):
171171
exclude=True,
172172
description="Human-friendly description of the rule condition.",
173173
)
174-
detects_violation: Callable[[float | None], bool] = Field(
174+
detects_violation: Callable[[float], bool] = Field(
175175
exclude=True,
176176
description="Function that returns True if the number violates the rule (validation should fail).",
177177
)
@@ -189,7 +189,7 @@ class BooleanRule(BaseModel):
189189
exclude=True,
190190
description="Human-friendly description of the rule condition.",
191191
)
192-
detects_violation: Callable[[bool | None], bool] = Field(
192+
detects_violation: Callable[[bool], bool] = Field(
193193
exclude=True,
194194
description="Function that returns True if the boolean violates the rule (validation should fail).",
195195
)

0 commit comments

Comments
 (0)