mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 18:04:49 -04:00
Fix pep8 codestyle warnings
This commit is contained in:
parent
dfdda2c871
commit
db9ce032a4
21 changed files with 71 additions and 47 deletions
|
@ -37,6 +37,7 @@ class Clock(object):
|
|||
|
||||
def call_later(self, delay, callback):
|
||||
current_context = LoggingContext.current_context()
|
||||
|
||||
def wrapped_callback():
|
||||
LoggingContext.thread_local.current_context = current_context
|
||||
callback()
|
||||
|
|
|
@ -18,6 +18,7 @@ from twisted.internet import defer, reactor
|
|||
|
||||
from .logcontext import PreserveLoggingContext
|
||||
|
||||
|
||||
@defer.inlineCallbacks
|
||||
def sleep(seconds):
|
||||
d = defer.Deferred()
|
||||
|
@ -25,6 +26,7 @@ def sleep(seconds):
|
|||
with PreserveLoggingContext():
|
||||
yield d
|
||||
|
||||
|
||||
def run_on_reactor():
|
||||
""" This will cause the rest of the function to be invoked upon the next
|
||||
iteration of the main loop
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue