MCPcopy Index your code
hub / github.com/python/cpython / _is_exception

Function _is_exception

Lib/unittest/mock.py:78–82  ·  view source on GitHub ↗
(obj)

Source from the content-addressed store, hash-verified

76
77
78def _is_exception(obj):
79 return (
80 isinstance(obj, BaseException) or
81 isinstance(obj, type) and issubclass(obj, BaseException)
82 )
83
84
85def _extract_mock(obj):

Callers 4

__get_side_effectMethod · 0.85
_try_iterFunction · 0.85
_execute_mock_callMethod · 0.85
_execute_mock_callMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…