Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/dabeaz/python-cookbook
/ start
Method
start
src/13/making_a_stopwatch/stopwatch.py:9–12 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
7
self._start = None
8
9
def
start(self):
10
if
self._start is not None:
11
raise
RuntimeError(
'Already started'
)
12
self._start = self._func()
13
14
def
end(self):
15
if
self._start is None:
Callers
6
__enter__
Method · 0.95
stopwatch.py
File · 0.45
rpc_server
Function · 0.45
rpc_server
Function · 0.45
threadedserv.py
File · 0.45
server1.py
File · 0.45
Calls
no outgoing calls
Tested by
no test coverage detected