diff --git a/cms/pytest.ini b/cms/pytest.ini index 2ef7c09ea3..14f323546b 100644 --- a/cms/pytest.ini +++ b/cms/pytest.ini @@ -8,6 +8,8 @@ filterwarnings = default ignore:No request passed to the backend, unable to rate-limit:UserWarning ignore::xblock.exceptions.FieldDataDeprecationWarning + ignore::django.utils.deprecation.RemovedInDjango40Warning + ignore::django.utils.deprecation.RemovedInDjango41Warning norecursedirs = envs python_classes = python_files = test.py tests.py test_*.py *_tests.py diff --git a/common/lib/pytest.ini b/common/lib/pytest.ini index bed2897487..d169959544 100644 --- a/common/lib/pytest.ini +++ b/common/lib/pytest.ini @@ -9,6 +9,8 @@ filterwarnings = default ignore:No request passed to the backend, unable to rate-limit:UserWarning ignore::xblock.exceptions.FieldDataDeprecationWarning + ignore::django.utils.deprecation.RemovedInDjango40Warning + ignore::django.utils.deprecation.RemovedInDjango41Warning markers = mongo norecursedirs = .cache diff --git a/common/test/pytest.ini b/common/test/pytest.ini index 29effd3a75..9ae1d23a98 100644 --- a/common/test/pytest.ini +++ b/common/test/pytest.ini @@ -7,4 +7,6 @@ filterwarnings = default ignore:No request passed to the backend, unable to rate-limit:UserWarning ignore::xblock.exceptions.FieldDataDeprecationWarning + ignore::django.utils.deprecation.RemovedInDjango40Warning + ignore::django.utils.deprecation.RemovedInDjango41Warning norecursedirs = .cache diff --git a/openedx/core/lib/logsettings.py b/openedx/core/lib/logsettings.py index 6159c19778..8762147a9a 100644 --- a/openedx/core/lib/logsettings.py +++ b/openedx/core/lib/logsettings.py @@ -129,9 +129,9 @@ def log_python_warnings(): try: # There are far too many of these deprecation warnings in startup to output for every management command; # suppress them until we've fixed at least the most common ones as reported by the test suite - from django.utils.deprecation import RemovedInDjango20Warning, RemovedInDjango21Warning - warnings.simplefilter('ignore', RemovedInDjango20Warning) - warnings.simplefilter('ignore', RemovedInDjango21Warning) + from django.utils.deprecation import RemovedInDjango40Warning, RemovedInDjango41Warning + warnings.simplefilter('ignore', RemovedInDjango40Warning) + warnings.simplefilter('ignore', RemovedInDjango41Warning) except ImportError: pass logging.captureWarnings(True) diff --git a/setup.cfg b/setup.cfg index 954ce7b818..bf7d54a3c1 100644 --- a/setup.cfg +++ b/setup.cfg @@ -8,6 +8,8 @@ filterwarnings = default ignore:No request passed to the backend, unable to rate-limit:UserWarning ignore::xblock.exceptions.FieldDataDeprecationWarning + ignore::django.utils.deprecation.RemovedInDjango40Warning + ignore::django.utils.deprecation.RemovedInDjango41Warning junit_family = xunit2 norecursedirs = .* *.egg build conf dist node_modules test_root cms/envs lms/envs python_classes =