diff options
author | Patrick Cloke <clokep@users.noreply.github.com> | 2020-09-04 06:54:56 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-04 06:54:56 -0400 |
commit | c619253db80c8d1c606dc40756dd3c9e3a55a9fb (patch) | |
tree | dad04bd2548edff6b3457f90fea11bc0eb803500 /synapse/util/async_helpers.py | |
parent | Revert "Add experimental support for sharding event persister. (#8170)" (#8242) (diff) | |
download | synapse-c619253db80c8d1c606dc40756dd3c9e3a55a9fb.tar.xz |
Stop sub-classing object (#8249)
Diffstat (limited to 'synapse/util/async_helpers.py')
-rw-r--r-- | synapse/util/async_helpers.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/synapse/util/async_helpers.py b/synapse/util/async_helpers.py index dfefbd996d..bb57e27beb 100644 --- a/synapse/util/async_helpers.py +++ b/synapse/util/async_helpers.py @@ -36,7 +36,7 @@ from synapse.util import Clock, unwrapFirstError logger = logging.getLogger(__name__) -class ObservableDeferred(object): +class ObservableDeferred: """Wraps a deferred object so that we can add observer deferreds. These observer deferreds do not affect the callback chain of the original deferred. @@ -188,7 +188,7 @@ def yieldable_gather_results(func, iter, *args, **kwargs): ).addErrback(unwrapFirstError) -class Linearizer(object): +class Linearizer: """Limits concurrent access to resources based on a key. Useful to ensure only a few things happen at a time on a given resource. @@ -338,7 +338,7 @@ class Linearizer(object): return new_defer -class ReadWriteLock(object): +class ReadWriteLock: """An async read write lock. Example: @@ -502,7 +502,7 @@ def timeout_deferred(deferred, timeout, reactor, on_timeout_cancel=None): @attr.s(slots=True, frozen=True) -class DoneAwaitable(object): +class DoneAwaitable: """Simple awaitable that returns the provided value. """ |