mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 12:06:08 -04:00
Merge remote-tracking branch 'origin/develop' into rav/use_run_in_background
This commit is contained in:
commit
fc149b4eeb
28 changed files with 412 additions and 257 deletions
|
@ -305,7 +305,12 @@ def run_in_background(f, *args, **kwargs):
|
|||
deferred returned by the funtion completes.
|
||||
|
||||
Useful for wrapping functions that return a deferred which you don't yield
|
||||
on.
|
||||
on (for instance because you want to pass it to deferred.gatherResults()).
|
||||
|
||||
Note that if you completely discard the result, you should make sure that
|
||||
`f` doesn't raise any deferred exceptions, otherwise a scary-looking
|
||||
CRITICAL error about an unhandled error will be logged without much
|
||||
indication about where it came from.
|
||||
"""
|
||||
current = LoggingContext.current_context()
|
||||
res = f(*args, **kwargs)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue