Skip to content

Openverse is a search engine for openly-licensed media. This monorepo includes all application code.

Bump schemathesis to 3.38.6 and silence its warning (#5166)

Krystle Salazar8af66912aafa
diff --git a/api/pdm.lock b/api/pdm.lock
index 1b20e5a50..1039694b7 100644
--- a/api/pdm.lock
+++ b/api/pdm.lock
@@ -5,7 +5,7 @@
groups = ["default", "dev", "overrides", "test"]
strategy = ["inherit_metadata"]
lock_version = "4.5.0"
-content_hash = "sha256:15a9263f5e3e619c09b6e1ce224fd11c843815f45496fa1b9261365d4161fb8e"
+content_hash = "sha256:99df69ada4a7606d30e3d7a2361fbe60bf129873d408d905644ed6d60af06a2b"
[[metadata.targets]]
requires_python = "==3.12.*"
@@ -1711,7 +1711,7 @@ files = [
[[package]]
name = "schemathesis"
-version = "3.38.3"
+version = "3.38.6"
requires_python = ">=3.8"
summary = "Property-based testing framework for Open API and GraphQL based apps"
groups = ["test"]
@@ -1740,8 +1740,8 @@ dependencies = [
"yarl<2.0,>=1.5",
]
files = [
- {file = "schemathesis-3.38.3-py3-none-any.whl", hash = "sha256:31a1765bed73767f10204b8e145347ce9bae7070e9dcccbe239c9ff8341f615b"},
- {file = "schemathesis-3.38.3.tar.gz", hash = "sha256:cb50aaf40a0d05d441937220678cdc23ab64a3d6256bcb9852d6d298a3fb25fe"},
+ {file = "schemathesis-3.38.6-py3-none-any.whl", hash = "sha256:5d294c7bd353c20565a72c3dbd23319a6b6305f29e0abc6e2bc278454ada1d19"},
+ {file = "schemathesis-3.38.6.tar.gz", hash = "sha256:c05beea65de8e1659625fcf0624c898781ebaecc63ffc1f1a5dfc15bf5a4b266"},
]
[[package]]
diff --git a/api/pyproject.toml b/api/pyproject.toml
index e3a0dc6e4..0957d0e9e 100644
--- a/api/pyproject.toml
+++ b/api/pyproject.toml
@@ -5,7 +5,7 @@ description = "API for the Openverse project"
readme = "README.md"
license = {text = "MIT"}
authors = [
- {name = "Openverse Contributors", email = "[email protected]"},
+ {name = "Openverse Contributors", email = "[email protected]"},
]
requires-python = "==3.12.*"
@@ -46,7 +46,7 @@ distribution = false
[tool.pdm.dev-dependencies]
# These packages override their main counterparts with an editable installation.
overrides = [
- "-e openverse-attribution @ file:///${PROJECT_ROOT}/../packages/python/openverse-attribution"
+ "-e openverse-attribution @ file:///${PROJECT_ROOT}/../packages/python/openverse-attribution"
]
dev = [
"ipython >=8.22.1, <9",
@@ -59,16 +59,16 @@ dev = [
"watchfiles>=0.24.0",
]
test = [
- "factory-boy >=3.3.0, <4",
- "fakeredis >=2.21.3, <3",
- "freezegun >=1.4.0, <2",
- "pook >=2, <3",
- "pytest >=8.3.3, <9",
- "pytest-django >=4.8.0, <5",
- "pytest-pook>=1.0.0",
- "pytest-raises >=0.11, <0.12",
- "pytest-sugar >=1, <1.1",
- "schemathesis >=3.25.6, <4",
+ "factory-boy >=3.3.0, <4",
+ "fakeredis >=2.21.3, <3",
+ "freezegun >=1.4.0, <2",
+ "pook >=2, <3",
+ "pytest >=8.3.3, <9",
+ "pytest-django >=4.8.0, <5",
+ "pytest-pook>=1.0.0",
+ "pytest-raises >=0.11, <0.12",
+ "pytest-sugar >=1, <1.1",
+ "schemathesis >=3.38.6, <4",
]
[tool.pytest.ini_options]
@@ -77,14 +77,14 @@ DJANGO_SETTINGS_MODULE = "conf.settings"
pythonpath = "."
filterwarnings = [
- # Ignore warnings related to unverified HTTPS requests.
- # Reason: This warning is suppressed to avoid raising warnings when making HTTP requests
- # to servers with invalid or self-signed SSL certificates. It allows the tests to proceed
- # without being interrupted by these warnings.
- "ignore:Unverified HTTPS request",
+ # Ignore warnings related to unverified HTTPS requests.
+ # Reason: This warning is suppressed to avoid raising warnings when making HTTP requests
+ # to servers with invalid or self-signed SSL certificates. It allows the tests to proceed
+ # without being interrupted by these warnings.
+ "ignore:Unverified HTTPS request",
- # Ignore warnings about the upcoming change in the default value of 'USE_TZ' setting in Django 5.0.
- # Reason: The reason this warning is suppressed is actually because we already set USE_TZ to True.
- # Since no changes are required on our part, we can safely ignore this to declutter the logs.
- "ignore:The default value of USE_TZ will change from False to True in Django 5.0",
+ # Ignore warnings coming from schemathesis.
+ # Reason: These are warnings raised by the library itself and are not relevant to our codebase.
+ "ignore:jsonschema.RefResolver is deprecated as of v4.18.0",
+ "ignore:jsonschema.exceptions.RefResolutionError is deprecated as of version 4.18.0.",
]
diff --git a/api/test/integration/test_auth.py b/api/test/integration/test_auth.py
index c24613530..69a58e70d 100644
--- a/api/test/integration/test_auth.py
+++ b/api/test/integration/test_auth.py
@@ -35,7 +35,6 @@ def unreachable_oauth_cache(unreachable_django_cache, monkeypatch):
yield cache
@pytest.fixture
def test_auth_tokens_registration(api_client):
data = {
@@ -53,7 +52,6 @@ def test_auth_tokens_registration(api_client):
return res_data
@pytest.fixture
def test_auth_token_exchange(api_client, test_auth_tokens_registration):
api_client_id = test_auth_tokens_registration["client_id"]