MCPcopy
hub / github.com/pydantic/pydantic / errors

Method errors

pydantic-core/tests/test_custom_errors.py:43–49  ·  view source on GitHub ↗
(
            self, *, include_url: bool = True, include_context: bool = True, include_input: bool = True
        )

Source from the content-addressed store, hash-verified

41
42 @override
43 def errors(
44 self, *, include_url: bool = True, include_context: bool = True, include_input: bool = True
45 ) -> list[ErrorDetails]:
46 errors = super().errors(
47 include_url=include_url, include_context=include_context, include_input=include_input
48 )
49 return [{**error, 'loc': error['loc'][1:]} for error in errors]
50
51 with pytest.raises(CustomLocOverridesError) as exception_info:
52 raise CustomLocOverridesError.from_exception_data(

Calls

no outgoing calls

Tested by

no test coverage detected