Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bslatkin/effectivepython
/ MyError
Class
MyError
example_code/item_111.py:130–131 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
128
print(
"Example 9"
)
129
try
:
130
class
MyError(Exception):
131
pass
132
133
mock = Mock(spec=get_animals)
134
mock.side_effect = MyError(
"Whoops! Big problem"
)
Callers
1
item_111.py
File · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected