cadwyn 5.4.5__tar.gz → 5.5.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of cadwyn might be problematic. Click here for more details.

Files changed (159) hide show
  1. {cadwyn-5.4.5 → cadwyn-5.5.0}/CHANGELOG.md +16 -3
  2. {cadwyn-5.4.5 → cadwyn-5.5.0}/PKG-INFO +3 -3
  3. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/changelogs.py +19 -17
  4. {cadwyn-5.4.5 → cadwyn-5.5.0}/pyproject.toml +3 -3
  5. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_render.py +0 -2
  6. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/test_schema_field.py +11 -10
  7. {cadwyn-5.4.5 → cadwyn-5.5.0}/uv.lock +3 -3
  8. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/CODE_OF_CONDUCT.md +0 -0
  9. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
  10. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
  11. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/actions/setup-python-uv/action.yaml +0 -0
  12. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/workflows/ci.yaml +0 -0
  13. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/workflows/daily_tests.yaml +0 -0
  14. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/workflows/publish_docs.yaml +0 -0
  15. {cadwyn-5.4.5 → cadwyn-5.5.0}/.github/workflows/release.yaml +0 -0
  16. {cadwyn-5.4.5 → cadwyn-5.5.0}/.gitignore +0 -0
  17. {cadwyn-5.4.5 → cadwyn-5.5.0}/.pre-commit-config.yaml +0 -0
  18. {cadwyn-5.4.5 → cadwyn-5.5.0}/LICENSE +0 -0
  19. {cadwyn-5.4.5 → cadwyn-5.5.0}/Makefile +0 -0
  20. {cadwyn-5.4.5 → cadwyn-5.5.0}/README.md +0 -0
  21. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/__init__.py +0 -0
  22. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/__main__.py +0 -0
  23. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_asts.py +0 -0
  24. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_importer.py +0 -0
  25. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_internal/__init__.py +0 -0
  26. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_internal/context_vars.py +0 -0
  27. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_render.py +0 -0
  28. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/_utils.py +0 -0
  29. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/applications.py +0 -0
  30. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/dependencies.py +0 -0
  31. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/exceptions.py +0 -0
  32. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/middleware.py +0 -0
  33. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/py.typed +0 -0
  34. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/route_generation.py +0 -0
  35. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/routing.py +0 -0
  36. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/schema_generation.py +0 -0
  37. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/static/__init__.py +0 -0
  38. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/static/docs.html +0 -0
  39. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/__init__.py +0 -0
  40. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/common.py +0 -0
  41. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/data.py +0 -0
  42. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/endpoints.py +0 -0
  43. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/enums.py +0 -0
  44. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/schemas.py +0 -0
  45. {cadwyn-5.4.5 → cadwyn-5.5.0}/cadwyn/structure/versions.py +0 -0
  46. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/CNAME +0 -0
  47. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/__init__.py +0 -0
  48. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/api_version_parameter.md +0 -0
  49. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/beware_of_data_versioning.md +0 -0
  50. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/changelogs.md +0 -0
  51. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/cli.md +0 -0
  52. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/endpoint_migrations.md +0 -0
  53. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/enum_migrations.md +0 -0
  54. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/index.md +0 -0
  55. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/main_app.md +0 -0
  56. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/methodology.md +0 -0
  57. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/schema_generation.md +0 -0
  58. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/schema_migrations.md +0 -0
  59. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/testing.md +0 -0
  60. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/concepts/version_changes.md +0 -0
  61. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/home/CONTRIBUTING.md +0 -0
  62. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_business_logic/index.md +0 -0
  63. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_endpoints/index.md +0 -0
  64. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/add_field.md +0 -0
  65. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/change_field_type.md +0 -0
  66. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/change_schema_without_endpoint.md +0 -0
  67. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/changing_constraints.md +0 -0
  68. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/remove_field.md +0 -0
  69. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/change_openapi_schemas/rename_a_field_in_schema.md +0 -0
  70. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/index.md +0 -0
  71. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/how_to/version_with_paths_and_numbers_instead_of_headers_and_dates.md +0 -0
  72. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/dashboard_with_one_version.png +0 -0
  73. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/dashboard_with_two_versions.png +0 -0
  74. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/get_users_endpoint_from_prior_version.png +0 -0
  75. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/logos/cadwyn_icon_transparent.svg +0 -0
  76. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/logos/cadwyn_transparent.svg +0 -0
  77. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/logos/cadwyn_with_background.svg +0 -0
  78. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/simplified_migration_model.png +0 -0
  79. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/img/unversioned_dashboard.png +0 -0
  80. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/index.md +0 -0
  81. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/plugin.py +0 -0
  82. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/quickstart/setup.md +0 -0
  83. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/quickstart/tutorial.md +0 -0
  84. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/stylesheets/extra.css +0 -0
  85. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/theory/how_to_build_versioning_framework.md +0 -0
  86. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/theory/how_we_got_here.md +0 -0
  87. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs/theory/literature.md +0 -0
  88. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/__init__.py +0 -0
  89. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/__init__.py +0 -0
  90. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/__init__.py +0 -0
  91. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/__init__.py +0 -0
  92. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/block001.py +0 -0
  93. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/block002.py +0 -0
  94. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/tests/__init__.py +0 -0
  95. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/tests/test_block001.py +0 -0
  96. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/change_openapi_schemas/change_schema_without_endpoint/tests/test_block002.py +0 -0
  97. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/version_with_path_and_numbers_instead_of_headers_and_dates/__init__.py +0 -0
  98. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/version_with_path_and_numbers_instead_of_headers_and_dates/block001.py +0 -0
  99. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/version_with_path_and_numbers_instead_of_headers_and_dates/tests/__init__.py +0 -0
  100. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/how_to/version_with_path_and_numbers_instead_of_headers_and_dates/tests/test_block_001.py +0 -0
  101. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/__init__.py +0 -0
  102. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/setup/__init__.py +0 -0
  103. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/setup/block001.sh +0 -0
  104. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/setup/block002.py +0 -0
  105. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/setup/tests/__init__.py +0 -0
  106. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/setup/tests/test_block002.py +0 -0
  107. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/__init__.py +0 -0
  108. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/block001.py +0 -0
  109. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/block002.py +0 -0
  110. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/block003.py +0 -0
  111. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/tests/__init__.py +0 -0
  112. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/tests/test_block001.py +0 -0
  113. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/tests/test_block002.py +0 -0
  114. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/quickstart/tutorial/tests/test_block003.py +0 -0
  115. {cadwyn-5.4.5 → cadwyn-5.5.0}/docs_src/ruff.toml +0 -0
  116. {cadwyn-5.4.5 → cadwyn-5.5.0}/mkdocs.yml +0 -0
  117. {cadwyn-5.4.5 → cadwyn-5.5.0}/ruff.toml +0 -0
  118. {cadwyn-5.4.5 → cadwyn-5.5.0}/scripts/fix_links.py +0 -0
  119. {cadwyn-5.4.5 → cadwyn-5.5.0}/scripts/split_md.py +0 -0
  120. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/__init__.py +0 -0
  121. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_data/__init__.py +0 -0
  122. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_data/unversioned_schema_dir/__init__.py +0 -0
  123. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_data/unversioned_schema_dir/unversioned_schemas.py +0 -0
  124. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_data/unversioned_schemas.py +0 -0
  125. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/__init__.py +0 -0
  126. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/app_for_testing_routing.py +0 -0
  127. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/__init__.py +0 -0
  128. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/classes.py +0 -0
  129. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/complex/__init__.py +0 -0
  130. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/complex/classes.py +0 -0
  131. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/complex/versions.py +0 -0
  132. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/render/versions.py +0 -0
  133. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/utils.py +0 -0
  134. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/versioned_app/__init__.py +0 -0
  135. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/versioned_app/app.py +0 -0
  136. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/versioned_app/v2021_01_01.py +0 -0
  137. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/versioned_app/v2022_01_02.py +0 -0
  138. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/_resources/versioned_app/webhooks.py +0 -0
  139. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/conftest.py +0 -0
  140. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_applications.py +0 -0
  141. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_auth_dependencies.py +0 -0
  142. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_changelog.py +0 -0
  143. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_cli.py +0 -0
  144. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_data_migrations.py +0 -0
  145. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_router_generation.py +0 -0
  146. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_router_generation_with_from_future_annotations.py +0 -0
  147. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_routing.py +0 -0
  148. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/__init__.py +0 -0
  149. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/test_enum.py +0 -0
  150. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/test_schema.py +0 -0
  151. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/test_schema_validator.py +0 -0
  152. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_schema_generation/test_schema_with_future_annotations.py +0 -0
  153. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/test_structure.py +0 -0
  154. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/tutorial/__init__.py +0 -0
  155. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/tutorial/main.py +0 -0
  156. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/tutorial/test_example.py +0 -0
  157. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/versioning_styles/__init__.py +0 -0
  158. {cadwyn-5.4.5 → cadwyn-5.5.0}/tests/versioning_styles/test_versioning_formats.py +0 -0
  159. {cadwyn-5.4.5 → cadwyn-5.5.0}/tox.ini +0 -0
@@ -5,6 +5,20 @@ Please follow [the Keep a Changelog standard](https://keepachangelog.com/en/1.0.
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [5.5.0]
9
+
10
+ * Fix the rest of the issues from fastapi==0.119.0
11
+
12
+ ## [5.4.5]
13
+
14
+ ### Fixed
15
+
16
+ * Many issues after GenerateJsonSchema getting removed in fastapi==0.119.0
17
+
18
+ ### Changed
19
+
20
+ * A lot of documentation improvements by @Shigerman
21
+
8
22
  ## [5.4.4]
9
23
 
10
24
  ### Fixed
@@ -33,9 +47,8 @@ Please follow [the Keep a Changelog standard](https://keepachangelog.com/en/1.0.
33
47
 
34
48
  ### Added
35
49
 
36
- - `typing_inspection` dependency from pydantic team for complex isinstance checks that must be the same between `typing` and `typing_extensions`
37
- - Support for `pydantic>=2.12.0` FieldInfo refactoring from https://github.com/pydantic/pydantic/pull/11898
38
-
50
+ * `typing_inspection` dependency from pydantic team for complex isinstance checks that must be the same between `typing` and `typing_extensions`
51
+ * Support for `pydantic>=2.12.0` FieldInfo refactoring from <https://github.com/pydantic/pydantic/pull/11898>
39
52
 
40
53
  ## [5.3.3]
41
54
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cadwyn
3
- Version: 5.4.5
3
+ Version: 5.5.0
4
4
  Summary: Production-ready community-driven modern Stripe-like API versioning in FastAPI
5
5
  Project-URL: Source code, https://github.com/zmievsa/cadwyn
6
6
  Project-URL: Documentation, https://docs.cadwyn.dev
@@ -35,14 +35,14 @@ Classifier: Topic :: Software Development :: Libraries :: Python Modules
35
35
  Classifier: Typing :: Typed
36
36
  Requires-Python: >=3.9
37
37
  Requires-Dist: backports-strenum<2,>=1.3.1; python_version < '3.11'
38
- Requires-Dist: fastapi>=0.112.4
38
+ Requires-Dist: fastapi>=0.119.0
39
39
  Requires-Dist: jinja2>=3.1.2
40
40
  Requires-Dist: pydantic>=2.11.0
41
41
  Requires-Dist: starlette>=0.30.0
42
42
  Requires-Dist: typing-extensions>=4.8.0
43
43
  Requires-Dist: typing-inspection>=0.4.0
44
44
  Provides-Extra: standard
45
- Requires-Dist: fastapi[standard]>=0.112.3; extra == 'standard'
45
+ Requires-Dist: fastapi[standard]>=0.119.0; extra == 'standard'
46
46
  Requires-Dist: typer>=0.7.0; extra == 'standard'
47
47
  Description-Content-Type: text/markdown
48
48
 
@@ -2,9 +2,13 @@ import copy
2
2
  import sys
3
3
  from enum import auto
4
4
  from logging import getLogger
5
- from typing import TYPE_CHECKING, Any, Literal, TypeVar, Union, cast, get_args
5
+ from typing import Any, Literal, TypeVar, Union, cast, get_args
6
6
 
7
- from fastapi.openapi.constants import REF_TEMPLATE
7
+ from fastapi._compat import (
8
+ get_compat_model_name_map,
9
+ get_definitions,
10
+ )
11
+ from fastapi._compat.v2 import ModelField
8
12
  from fastapi.openapi.utils import (
9
13
  get_fields_from_routes,
10
14
  get_openapi,
@@ -35,9 +39,6 @@ from .structure.schemas import (
35
39
  ValidatorExistedInstruction,
36
40
  )
37
41
 
38
- if TYPE_CHECKING:
39
- from fastapi._compat import ModelField
40
-
41
42
  if sys.version_info >= (3, 11): # pragma: no cover
42
43
  from enum import StrEnum
43
44
  else: # pragma: no cover
@@ -89,7 +90,7 @@ def _generate_changelog(versions: VersionBundle, router: _RootCadwynAPIRouter) -
89
90
  version_change,
90
91
  generator_from_newer_version,
91
92
  generator_from_older_version,
92
- schemas_from_older_version,
93
+ schemas_from_older_version, # pyright: ignore[reportArgumentType]
93
94
  cast("list[APIRoute]", routes_from_newer_version),
94
95
  )
95
96
  if changelog_entry is not None: # pragma: no branch # This should never happen
@@ -153,21 +154,22 @@ def _get_all_pydantic_models_from_generic(annotation: Any) -> list[type[BaseMode
153
154
 
154
155
 
155
156
  def _get_openapi_representation_of_a_field(model: type[BaseModel], field_name: str) -> dict:
156
- from fastapi._compat import (
157
- GenerateJsonSchema,
158
- ModelField,
159
- get_compat_model_name_map,
160
- get_definitions,
161
- )
162
-
163
157
  class CadwynDummyModelForRepresentation(BaseModel):
164
158
  my_field: model
165
159
 
166
- model_name_map = get_compat_model_name_map([CadwynDummyModelForRepresentation.model_fields["my_field"]])
167
- schema_generator = GenerateJsonSchema(ref_template=REF_TEMPLATE)
160
+ model_name_map = get_compat_model_name_map(
161
+ [
162
+ CadwynDummyModelForRepresentation.model_fields["my_field"], # pyright: ignore[reportArgumentType]
163
+ ]
164
+ )
165
+
168
166
  _, definitions = get_definitions(
169
- fields=[ModelField(CadwynDummyModelForRepresentation.model_fields["my_field"], "my_field")],
170
- schema_generator=schema_generator,
167
+ fields=[
168
+ ModelField(
169
+ CadwynDummyModelForRepresentation.model_fields["my_field"],
170
+ "my_field",
171
+ ), # pyright: ignore[reportArgumentType]
172
+ ],
171
173
  model_name_map=model_name_map,
172
174
  separate_input_output_schemas=False,
173
175
  )
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "cadwyn"
3
- version = "5.4.5"
3
+ version = "5.5.0"
4
4
  description = "Production-ready community-driven modern Stripe-like API versioning in FastAPI"
5
5
  authors = [{ name = "Stanislav Zmiev", email = "zmievsa@gmail.com" }]
6
6
  license = "MIT"
@@ -51,7 +51,7 @@ classifiers = [
51
51
  "Topic :: Internet :: WWW/HTTP",
52
52
  ]
53
53
  dependencies = [
54
- "fastapi >=0.112.4",
54
+ "fastapi >=0.119.0",
55
55
  "starlette >=0.30.0",
56
56
  "pydantic >=2.11.0",
57
57
  "jinja2 >=3.1.2",
@@ -62,7 +62,7 @@ dependencies = [
62
62
 
63
63
 
64
64
  [project.optional-dependencies]
65
- standard = ["fastapi[standard]>=0.112.3", "typer>=0.7.0"]
65
+ standard = ["fastapi[standard]>=0.119.0", "typer>=0.7.0"]
66
66
 
67
67
  [tool.uv]
68
68
  dev-dependencies = [
@@ -10,8 +10,6 @@ from cadwyn.structure.versions import Version, VersionBundle
10
10
  from tests.test_cli import code
11
11
 
12
12
 
13
- # TODO: Return this test once https://github.com/pydantic/pydantic/pull/11898 is merged
14
- @pytest.mark.xfail
15
13
  def test__render_model__with_weird_types():
16
14
  result = render_model_by_path(
17
15
  "tests._resources.render.complex.classes:ModelWithWeirdFields",
@@ -68,16 +68,17 @@ def test__field_existed_as__original_schema_has_a_field(create_runtime_schemas:
68
68
 
69
69
 
70
70
  def test__field_existed_as__extras_are_added(create_runtime_schemas: CreateRuntimeSchemas):
71
- schemas = create_runtime_schemas(
72
- version_change(
73
- schema(EmptySchema)
74
- .field("foo")
75
- .existed_as(
76
- type=int,
77
- info=Field(deflolbtt="hewwo"), # pyright: ignore[reportCallIssue]
78
- ),
71
+ with pytest.warns(DeprecationWarning):
72
+ schemas = create_runtime_schemas(
73
+ version_change(
74
+ schema(EmptySchema)
75
+ .field("foo")
76
+ .existed_as(
77
+ type=int,
78
+ info=Field(deflolbtt="hewwo"), # pyright: ignore[reportCallIssue]
79
+ ),
80
+ )
79
81
  )
80
- )
81
82
 
82
83
  class ExpectedSchema(BaseModel):
83
84
  foo: int = Field(json_schema_extra={"deflolbtt": "hewwo"})
@@ -266,7 +267,7 @@ def test__schema_field_had__decimal_field(attr: str, attr_value: Any, create_run
266
267
 
267
268
  @pytest.mark.parametrize(
268
269
  ("attr", "attr_value"),
269
- [("exclude", [16, 17, 18])],
270
+ [("exclude", True)],
270
271
  )
271
272
  def test__schema_field_had__list_of_int_field(attr: str, attr_value: Any, create_runtime_schemas: CreateRuntimeSchemas):
272
273
  class SchemaWithOneListOfIntField(BaseModel):
@@ -99,7 +99,7 @@ wheels = [
99
99
 
100
100
  [[package]]
101
101
  name = "cadwyn"
102
- version = "5.4.5"
102
+ version = "5.5.0"
103
103
  source = { editable = "." }
104
104
  dependencies = [
105
105
  { name = "backports-strenum", marker = "python_full_version < '3.11'" },
@@ -144,8 +144,8 @@ dev = [
144
144
  [package.metadata]
145
145
  requires-dist = [
146
146
  { name = "backports-strenum", marker = "python_full_version < '3.11'", specifier = ">=1.3.1,<2" },
147
- { name = "fastapi", specifier = ">=0.112.4" },
148
- { name = "fastapi", extras = ["standard"], marker = "extra == 'standard'", specifier = ">=0.112.3" },
147
+ { name = "fastapi", specifier = ">=0.119.0" },
148
+ { name = "fastapi", extras = ["standard"], marker = "extra == 'standard'", specifier = ">=0.119.0" },
149
149
  { name = "jinja2", specifier = ">=3.1.2" },
150
150
  { name = "pydantic", specifier = ">=2.11.0" },
151
151
  { name = "starlette", specifier = ">=0.30.0" },
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes