mirror of
https://github.com/python/cpython.git
synced 2025-07-24 19:54:21 +00:00
bpo-44498: suppress DeprecationWarnings for asynchat, asyncore and smtpd in tests (GH-26905) (GH-26907)
(cherry picked from commit 22e7effad5
)
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
This commit is contained in:
parent
a80a38ee9a
commit
8bec9fb92f
9 changed files with 51 additions and 16 deletions
|
@ -21,7 +21,6 @@ import pprint
|
|||
import urllib.request
|
||||
import threading
|
||||
import traceback
|
||||
import asyncore
|
||||
import weakref
|
||||
import platform
|
||||
import sysconfig
|
||||
|
@ -31,6 +30,11 @@ try:
|
|||
except ImportError:
|
||||
ctypes = None
|
||||
|
||||
import warnings
|
||||
with warnings.catch_warnings():
|
||||
warnings.simplefilter('ignore', DeprecationWarning)
|
||||
import asyncore
|
||||
|
||||
ssl = import_helper.import_module("ssl")
|
||||
import _ssl
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue