chore: ignore HTTPResponse.getheaders() deprecation warning

related issue: https://github.com/openedx/edx-platform/issues/33584

note: this warning is rased from a third party library (elasticsearch)
This commit is contained in:
Daniel Valenzuela
2023-10-25 19:53:36 -03:00
parent 66c5be8c02
commit d2f427a672
4 changed files with 11 additions and 0 deletions

View File

@@ -14,6 +14,8 @@ filterwarnings =
ignore::xblock.exceptions.FieldDataDeprecationWarning
# Remove default_app_config warning after updating Django to 4.2
ignore:.*You can remove default_app_config.*:PendingDeprecationWarning
ignore:Instead access HTTPResponse.headers directly.*:DeprecationWarning:elasticsearch
norecursedirs = envs
python_classes =
python_files = test.py tests.py test_*.py *_tests.py

View File

@@ -13,4 +13,6 @@ filterwarnings =
ignore::xblock.exceptions.FieldDataDeprecationWarning
# Remove default_app_config warning after updating Django to 4.2
ignore:.*You can remove default_app_config.*:PendingDeprecationWarning
ignore:Instead access HTTPResponse.headers directly.*:DeprecationWarning:elasticsearch
norecursedirs = .cache

View File

@@ -132,6 +132,12 @@ def log_python_warnings():
'.*You can remove default_app_config.*',
category=PendingDeprecationWarning
)
warnings.filterwarnings(
'ignore',
'Instead access HTTPResponse.headers directly.*',
category=DeprecationWarning,
module='elasticsearch'
)
# 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

View File

@@ -14,6 +14,7 @@ filterwarnings =
ignore::xblock.exceptions.FieldDataDeprecationWarning
# Remove default_app_config warning after updating Django to 4.2
ignore:.*You can remove default_app_config.*:PendingDeprecationWarning
ignore:Instead access HTTPResponse.headers directly.*:DeprecationWarning:elasticsearch
junit_family = xunit2
norecursedirs = .* *.egg build conf dist node_modules test_root cms/envs lms/envs