Skip to content

Commit

Permalink
pydatnic 2.9 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalik committed Sep 17, 2024
1 parent 40dc996 commit 3584a26
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions ninja/openapi/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,8 @@ def flatten_properties(
# is_required = "default" not in prop_details
yield prop_name, prop_details, prop_required
else:
# pragma: no cover
# TODO: this code was for pydanitc 1.7+ ... <2.9 - check if this is still needed
for item in prop_details["allOf"]:
yield from flatten_properties("", item, True, definitions)

Expand Down
2 changes: 1 addition & 1 deletion tests/test_with_django/test_multi_param_parsing.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import re
import json
import re
from pathlib import Path

import pytest
Expand Down

0 comments on commit 3584a26

Please sign in to comment.