From bced52953a9ed083e1013f78c707f7f6f353adc9 Mon Sep 17 00:00:00 2001 From: Thomas Desveaux Date: Mon, 3 Jun 2024 15:43:52 +0200 Subject: [PATCH] test: remove ignore warnings that are no longer necessary --- master/buildbot/test/__init__.py | 88 -------------------------------- 1 file changed, 88 deletions(-) diff --git a/master/buildbot/test/__init__.py b/master/buildbot/test/__init__.py index 09e75bfa1538..d453837e8602 100644 --- a/master/buildbot/test/__init__.py +++ b/master/buildbot/test/__init__.py @@ -61,103 +61,15 @@ 'ignore', "Not importing directory.*docker': missing __init__.py", category=ImportWarning ) -# FIXME: needs to be sorted out (#3666) -warnings.filterwarnings('ignore', "1300 Invalid utf8 character string") - -# twisted.compat.execfile is using 'U' https://twistedmatrix.com/trac/ticket/9023 -warnings.filterwarnings('ignore', "'U' mode is deprecated", DeprecationWarning) - -# twisted.python.filepath and trial are using bytes file paths when -# the "native" file path (Unicode) should be used on Windows. -warnings.filterwarnings( - 'ignore', "The Windows bytes API has been deprecated, use Unicode filenames instead" -) -# moto warning v1.0.0 -warnings.filterwarnings('ignore', "Flags not at the start of the expression") -warnings.filterwarnings('ignore', r"object\(\) takes no parameters") - -# this warning happens sometimes on python3.4 -warnings.filterwarnings('ignore', r"The value of convert_charrefs will become True in 3.5") - -# Twisted 18.4+ adds a deprecation warning and still use the deprecated API in its own code! -warnings.filterwarnings('ignore', ".*getClientIP was deprecated.*", DeprecationWarning) - -# Python 3.7 adds a deprecation importing ABCs from collection. -# Such imports are made in dependencies (e.g moto, werzeug, pyparsing) -warnings.filterwarnings( - 'ignore', ".*Using or importing the ABCs from 'collections'.*", DeprecationWarning -) - -# more 3.7 warning from moto -warnings.filterwarnings( - 'ignore', r".*Use 'list\(elem\)' or iteration over elem instead.*", DeprecationWarning -) -warnings.filterwarnings( - 'ignore', r".*distutils Version classes are deprecated.*", DeprecationWarning -) - # ignore ResourceWarnings for unclosed sockets for the pg8000 driver on Python 3+ (tech debt: #4508) if sys.version_info[0] >= 3 and "pg8000" in os.getenv("BUILDBOT_TEST_DB_URL", ""): warnings.filterwarnings('ignore', ".*unclosed .*socket", ResourceWarning) -# ignore ResourceWarnings when connecting to a HashiCorp vault via hvac in integration tests -warnings.filterwarnings('ignore', r".*unclosed .*socket.*raddr=.*, 8200[^\d]", ResourceWarning) - -# Python 3.5-3.8 shows this warning -warnings.filterwarnings('ignore', ".*the imp module is deprecated in favour of importlib*") - -# Python 3.3-3.7 show this warning and in invoked from autobahn -warnings.filterwarnings('ignore', ".*time.clock has been deprecated in Python 3.3.*") - -# ignore an attrs API warning for APIs used in dependencies -warnings.filterwarnings( - 'ignore', - ".*The usage of `cmp` is deprecated and will be removed on or after.*", - DeprecationWarning, -) - -# ignore warnings from importing lib2to3 via buildbot_pkg -> -# setuptools.command.build_py -> setuptools.lib2to3_ex -> lib2to3 -# https://github.com/pypa/setuptools/issues/2086 -warnings.filterwarnings( - 'ignore', ".*lib2to3 package is deprecated", category=PendingDeprecationWarning -) - -# on python 3.9, this warning is generated by the stdlib -warnings.filterwarnings( - 'ignore', ".*The loop argument is deprecated since Python", category=DeprecationWarning -) - -# This warning is generated by the EC2 latent -warnings.filterwarnings( - 'ignore', ".*stream argument is deprecated. Use stream parameter", category=DeprecationWarning -) - -# Botocore imports deprecated urllib3.contrib.pyopenssl for backwards compatibility that we don't -# use. See https://github.com/boto/botocore/issues/2744 -warnings.filterwarnings( - 'ignore', ".*'urllib3.contrib.pyopenssl' module is deprecated", category=DeprecationWarning -) - -# boto3 shows this warning when on old Python -warnings.filterwarnings('ignore', ".*Boto3 will no longer support Python .*", category=Warning) - # autobahn is not updated for Twisted 22.04 and newer warnings.filterwarnings( "ignore", "twisted.web.resource.NoResource was deprecated in", category=DeprecationWarning ) -# Buildbot shows this warning after upgrading to Twisted 23.10 -warnings.filterwarnings('ignore', ".*unclosed event loop.*", category=Warning) - -# This warning is generated by graphql-core with Python 3.12. -# See https://github.com/graphql-python/graphql-core/issues/211 -warnings.filterwarnings( - 'ignore', - "'typing.ByteString' is deprecated and slated for removal in Python 3.14", - category=DeprecationWarning, -) - # When using Python 3.12, this generates some dependent package warnings.filterwarnings( 'ignore',