Skip to content

refactor: replace custom email validation with Pydantic EmailStr #971#1169

Open
bhaveshyab wants to merge 1 commit into
imDarshanGK:mainfrom
bhaveshyab:feature/pydantic-emailstr-971
Open

refactor: replace custom email validation with Pydantic EmailStr #971#1169
bhaveshyab wants to merge 1 commit into
imDarshanGK:mainfrom
bhaveshyab:feature/pydantic-emailstr-971

Conversation

@bhaveshyab

Copy link
Copy Markdown

Description

Replaced custom string-splitting and regex-like email verification rules with Pydantic's robust, RFC-compliant native EmailStr data type across the schemas (SignupRequest, LoginRequest, SubscribeRequest, SubscribeResponse, and UnsubscribeRequest). This deprecates and deletes manual @field_validator("email") hooks while improving validation accuracy.

Related Issue

Fixes #971

Type of change

  • Refactor

Checklist

  • I have read CONTRIBUTING.md
  • My branch is up to date with main
  • I have run pytest -v and all tests pass (451 passed)
  • This PR is linked to a GSSoC 2026 issue

Test evidence

============ 451 passed, 115 warnings in 43.28s ============

@bhaveshyab bhaveshyab requested a review from imDarshanGK as a code owner July 1, 2026 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace custom email validation with Pydantic EmailStr

1 participant