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

Method shutdown

Lib/socketserver.py:244–252  ·  view source on GitHub ↗

Stops the serve_forever loop. Blocks until the loop has finished. This must be called while serve_forever() is running in another thread, or it will deadlock.

(self)

Source from the content-addressed store, hash-verified

242 self.__is_shut_down.set()
243
244 def shutdown(self):
245 """Stops the serve_forever loop.
246
247 Blocks until the loop has finished. This must be called while
248 serve_forever() is running in another thread, or it will
249 deadlock.
250 """
251 self.__shutdown_request = True
252 self.__is_shut_down.wait()
253
254 def service_actions(self):
255 """Called by the serve_forever() loop.

Callers 1

shutdown_requestMethod · 0.45

Calls 1

waitMethod · 0.45

Tested by

no test coverage detected