Add example of traceback.format_exception.
This commit is contained in:
parent
628f18e0db
commit
a5f982300e
1 changed files with 3 additions and 0 deletions
|
@ -17,6 +17,9 @@ Here are some examples of threadpool in use:
|
||||||
>>> if job.value is not None:
|
>>> if job.value is not None:
|
||||||
>>> yield job.value
|
>>> yield job.value
|
||||||
|
|
||||||
|
Also consider:
|
||||||
|
log.error(''.join(traceback.format_exception(None, job.exception, job.exception.__traceback__)))
|
||||||
|
|
||||||
2. Git-fetching a bunch of repositories with no error handling:
|
2. Git-fetching a bunch of repositories with no error handling:
|
||||||
|
|
||||||
>>> def git_fetch(d):
|
>>> def git_fetch(d):
|
||||||
|
|
Loading…
Reference in a new issue