MCPcopy Create free account
hub / github.com/sissaschool/xmlschema / XMLSchemaNotBuiltError

Class XMLSchemaNotBuiltError

xmlschema/validators/exceptions.py:213–232  ·  view source on GitHub ↗

Raised when there is an improper usage attempt of a not built XSD validator. :param validator: the XSD validator. :param message: the error message. :param namespaces: is an optional mapping from namespace prefix to URI.

Source from the content-addressed store, hash-verified

211
212
213class XMLSchemaNotBuiltError(XMLSchemaValidatorError, RuntimeError):
214 """
215 Raised when there is an improper usage attempt of a not built XSD validator.
216
217 :param validator: the XSD validator.
218 :param message: the error message.
219 :param namespaces: is an optional mapping from namespace prefix to URI.
220 """
221 def __init__(self, validator: 'XsdValidator',
222 message: str,
223 namespaces: Optional[NsmapType] = None) -> None:
224 if namespaces is None:
225 namespaces = getattr(validator, 'namespaces', None)
226 super().__init__(
227 validator=validator,
228 message=message,
229 elem=getattr(validator, 'elem', None),
230 source=getattr(validator, 'source', None),
231 namespaces=namespaces
232 )
233
234
235class XMLSchemaParseError(XMLSchemaValidatorError, SyntaxError):

Callers 4

test_exception_initMethod · 0.90
check_validatorMethod · 0.85
__call__Method · 0.85
__init__Method · 0.85

Calls

no outgoing calls

Tested by 1

test_exception_initMethod · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…