diff --git a/fastapi-0.78.0-httpx-cgi-deprecation.patch b/fastapi-0.78.0-httpx-cgi-deprecation.patch new file mode 100644 index 0000000..9882640 --- /dev/null +++ b/fastapi-0.78.0-httpx-cgi-deprecation.patch @@ -0,0 +1,9 @@ +diff -Naur fastapi-0.78.0-original/pyproject.toml fastapi-0.78.0/pyproject.toml +--- fastapi-0.78.0-original/pyproject.toml 2022-05-14 15:58:04.000000000 -0400 ++++ fastapi-0.78.0/pyproject.toml 2022-06-28 10:35:38.576663484 -0400 +@@ -144,4 +144,5 @@ + 'ignore:starlette.middleware.wsgi is deprecated and will be removed in a future release\..*:DeprecationWarning:starlette', + # TODO: remove after dropping support for Python 3.6 + 'ignore:Python 3.6 is no longer supported by the Python core team. Therefore, support for it is deprecated in cryptography and will be removed in a future release.:UserWarning:jose', ++ "ignore:'cgi' is deprecated and slated for removal in Python 3\\.13:DeprecationWarning:httpx", + ] diff --git a/python-fastapi.spec b/python-fastapi.spec index b6aab6c..24facf3 100644 --- a/python-fastapi.spec +++ b/python-fastapi.spec @@ -25,11 +25,17 @@ BuildArch: noarch # # This PR includes the changes to bump from 0.19.1 to 0.20.0, corresponding to # https://github.com/tiangolo/fastapi/pull/4820. -Patch: %{url}/pull/4936.patch +Patch: %{url}/pull/4936.patch # Fix sql_app_py39 and py310 tests # https://github.com/tiangolo/fastapi/pull/4409 -Patch: %{url}/pull/4409.patch +Patch: %{url}/pull/4409.patch + +# Ignore Python 3.11-related deprecation warnings that bubble up from httpx and +# are treated as errors. This might be suitable for submission upstream, but it +# will be easier to get it looked at when more of FastAPI’s dependencies +# officially support Python 3.11. +Patch: fastapi-0.78.0-httpx-cgi-deprecation.patch BuildRequires: python3-devel