Skip to content

Reject bool for DNS timeout - #172

Open
Pitchfork-and-Torch wants to merge 1 commit into
JoshData:mainfrom
Pitchfork-and-Torch:cook/reject-bool-timeout
Open

Pitchfork-and-Torch wants to merge 1 commit into
JoshData:mainfrom
Pitchfork-and-Torch:cook/reject-bool-timeout

Conversation

@Pitchfork-and-Torch

Copy link
Copy Markdown

Summary

bool subclasses int, so timeout=True previously set resolver.lifetime = True and silently became a 1-second DNS timeout in caching_resolver / deliverability checks.

This change rejects bool explicitly for timeout in validate_email, caching_resolver, and validate_email_deliverability.

Test plan

  • Added test_timeout_rejects_bool
  • tests/test_deliverability.py passes

bool subclasses int, so timeout=True previously set resolver.lifetime
to True and silently became a 1-second DNS timeout. Reject bool
explicitly for timeout.
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.

1 participant