MCPcopy Create free account
hub / github.com/celery/celery / WithSafeHandleError

Class WithSafeHandleError

celery/utils/log.py:206–212  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

204 def wrap_handler(handler): # pragma: no cover
205
206 class WithSafeHandleError(logging.Handler):
207
208 def handleError(self, record):
209 try:
210 traceback.print_exc(None, sys.__stderr__)
211 except OSError:
212 pass # see python issue 5971
213
214 handler.handleError = WithSafeHandleError().handleError
215 return [wrap_handler(h) for h in self.logger.handlers]

Callers 1

wrap_handlerMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected