Skip to content

Commit 3fcf5d3

Browse files
authored
Make XMLSchema inputs optional (GH-108)
The parameters `etree` and `file` of the `XMLSchema` constructor are documented as `None` by default, so `None` should be a valid value.
1 parent 6832d61 commit 3fcf5d3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lxml-stubs/etree.pyi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -457,8 +457,8 @@ class Resolver:
457457
class XMLSchema(_Validator):
458458
def __init__(
459459
self,
460-
etree: _ElementOrTree = ...,
461-
file: _FileSource = ...,
460+
etree: Optional[_ElementOrTree] = ...,
461+
file: Optional[_FileSource] = ...,
462462
) -> None: ...
463463
def __call__(self, etree: _ElementOrTree) -> bool: ...
464464

0 commit comments

Comments
 (0)