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

Method worker

Lib/test/test_queue.py:156–164  ·  view source on GitHub ↗
(self, q)

Source from the content-addressed store, hash-verified

154
155
156 def worker(self, q):
157 while True:
158 x = q.get()
159 if x < 0:
160 q.task_done()
161 return
162 with self.cumlock:
163 self.cum += x
164 q.task_done()
165
166 def queue_join_test(self, q):
167 self.cum = 0

Callers

nothing calls this directly

Calls 2

getMethod · 0.45
task_doneMethod · 0.45

Tested by

no test coverage detected