Skip to content

Raise TypeError for invalid cert values#995

Open
Abdulmumin1 wants to merge 1 commit into
pydantic:mainfrom
Abdulmumin1:fix-cert-type-error
Open

Raise TypeError for invalid cert values#995
Abdulmumin1 wants to merge 1 commit into
pydantic:mainfrom
Abdulmumin1:fix-cert-type-error

Conversation

@Abdulmumin1
Copy link
Copy Markdown

Fixes #844.

Summary

  • normalize supported cert shapes before calling SSLContext.load_cert_chain
  • raise TypeError for unsupported cert values instead of silently ignoring them
  • add regression coverage for pathlib.Path, empty tuple, and invalid tuple lengths

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq Bot commented May 29, 2026

Merging this PR will not alter performance

✅ 15 untouched benchmarks
⏩ 7 skipped benchmarks1


Comparing Abdulmumin1:fix-cert-type-error (f4f8064) with main (999da32)

Open in CodSpeed

Footnotes

  1. 7 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

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.

_load_client_certs() should raise an error if cert could not be handled.

1 participant