gh-94172: Remove keyfile, certfile and check_hostname parameters by vstinner · Pull Request #94173 · python/cpython

@vstinner vstinner marked this pull request as ready for review

June 23, 2022 13:40

serhiy-storchaka

serhiy-storchaka

tiran

This was referenced

Jun 28, 2022

serhiy-storchaka

Remove the keyfile, certfile and check_hostname parameters,
deprecated since Python 3.6, in modules: ftplib, http.client,
imaplib, poplib and smtplib. Use the context parameter (ssl_context
in imaplib) instead.

Parameters following the removed parameters become keyword-only
parameters.

ftplib: Remove the FTP_TLS.ssl_version class attribute: use the
context parameter instead.
* poplib: stls() context parameter can be positional again
* Keep test_ftplib tests but replace ValueError with TypeError
* Reformat test_httplib
* Keep but update test_tls13_pha() test

donbarbos added a commit to donbarbos/typeshed that referenced this pull request

Jan 11, 2026

@donbarbos