Skip to content

The agent engineering platform.

community[patch]: Make the pydantic linter stricter (#24897)

Eugene Yurtsevadd16111b9ff
diff --git a/libs/community/scripts/check_pydantic.sh b/libs/community/scripts/check_pydantic.sh
index f82aea7e7e..1b091d0f4e 100755
--- a/libs/community/scripts/check_pydantic.sh
+++ b/libs/community/scripts/check_pydantic.sh
@@ -53,7 +53,7 @@ fi
# Forbid vanilla usage of @root_validator
# This prevents the code from using either @root_validator or @root_validator()
# Search for lines matching the pattern within the specified repository
-result=$(git -C "$repository_path" grep -En '(@root_validator\s*$)|(@root_validator\(\))' -- '*.py')
+result=$(git -C "$repository_path" grep -En '(@root_validator\s*$)|(@root_validator\(\)|@root_validator\(pre=False\))' -- '*.py')
# Check if any matching lines were found
if [ -n "$result" ]; then