catch all exceptions in worker thread