Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,8 +213,8 @@ We do our best to follow the rules below.

- Support the latest few releases of Python, currently Python 3.11 through 3.14.
- Support the latest few releases of Pyramid, currently 1.10.7 through 2.1.
- Support the latest few releases of `openapi-core`, currently just 0.19.0.
- See `poetry.lock` for a frozen-in-time known-good-set of all dependencies.
- Support the latest few releases of `openapi-core`, currently just 0.23.x.
- See `uv.lock` for a frozen-in-time known-good-set of all dependencies.

## Use in the wild

Expand Down
8 changes: 6 additions & 2 deletions examples/splitfile/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,12 @@ def test_bad_items(self) -> None:
res.json,
[
{
"exception": "DataValidationError",
"message": "Failed to cast value to object type: foo",
"exception": "ValidationError",
"message": "'foo' is not of type 'object'",
},
{
"exception": "ValidationError",
"message": "'bar' is not of type 'object'",
},
],
)
8 changes: 6 additions & 2 deletions examples/todoapp/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,12 @@ def test_bad_items(self) -> None:
res.json,
[
{
"exception": "DataValidationError",
"message": "Failed to cast value to object type: foo",
"exception": "ValidationError",
"message": "'foo' is not of type 'object'",
},
{
"exception": "ValidationError",
"message": "'bar' is not of type 'object'",
},
],
)
4 changes: 1 addition & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ classifiers = [
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
# openapi-core 0.23.0 removed SchemaPath.contents(), which this addon relies
# on. The supported line is 0.19.x (see README deprecation policy).
"openapi-core>=0.19.1,<0.20",
"openapi-core>=0.23.0,<0.24",
"pyramid>=1.10.7",
]

Expand Down
2 changes: 1 addition & 1 deletion pyramid_openapi3/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ def _create_api_settings(
)

# switch validator based on spec version
spec_version = get_spec_version(spec.contents())
spec_version = get_spec_version(spec.read_value())
request_unmarshallers = {
"OpenAPIV3.0": V30RequestUnmarshaller,
"OpenAPIV3.1": V31RequestUnmarshaller,
Expand Down
5 changes: 3 additions & 2 deletions pyramid_openapi3/tests/test_extract_errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -478,8 +478,9 @@ def test_lists(self) -> None:

assert res.json == [
{
"exception": "RequestBodyValidationError",
"message": "Failed to cast value to number type: not a number",
"exception": "ValidationError",
"message": "'not a number' is not of type 'number'",
"field": "foo/0/bam",
}
]

Expand Down
337 changes: 181 additions & 156 deletions uv-oldest.lock

Large diffs are not rendered by default.

342 changes: 183 additions & 159 deletions uv.lock

Large diffs are not rendered by default.

Loading