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

feat: modernize BanSubstrings with Pydantic v2 validation - #322

Open
cristianleoo wants to merge 1 commit into
protectai:mainfrom
cristianleoo:feat/pydantic-v2-ban-substrings
Open

cristianleoo wants to merge 1 commit into
protectai:mainfrom
cristianleoo:feat/pydantic-v2-ban-substrings

Conversation

@cristianleoo

Copy link
Copy Markdown

This PR introduces Pydantic v2 to formalize the configuration and validation logic of the BanSubstrings scanner.

  • Structured Config: Moves initialization parameters into a BanSubstringsConfig model.
  • Type Safety: Leverages Pydantic automatic type coercion and validation.
  • Performance: Prepares the codebase for Pydantic v2 performance benefits.
  • Cleanliness: Removes manual type checking boilerplate in favor of declarative type hints.

This branch has not been deployed

No deployments
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant