Skip to content

Commit 774157d

Browse files
authored
add MandatoryResolveType (#591)
1 parent 9995bfd commit 774157d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

schema_salad/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
Iterable,
1212
Mapping,
1313
MutableSequence,
14+
Optional,
1415
Tuple,
1516
TypeVar,
1617
Union,
@@ -29,7 +30,8 @@
2930
DocumentType = TypeVar("DocumentType", CommentedSeq, CommentedMap)
3031
DocumentOrStrType = TypeVar("DocumentOrStrType", CommentedSeq, CommentedMap, str)
3132
FieldType = TypeVar("FieldType", str, CommentedSeq, CommentedMap)
32-
ResolveType = Union[int, float, str, CommentedMap, CommentedSeq, None]
33+
MandatoryResolveType = Union[int, float, str, CommentedMap, CommentedSeq]
34+
ResolveType = Optional[MandatoryResolveType]
3335
ResolvedRefType = Tuple[ResolveType, CommentedMap]
3436
IdxResultType = Union[CommentedMap, CommentedSeq, str, None]
3537
IdxType = Dict[str, IdxResultType]

0 commit comments

Comments
 (0)