mirror of
https://github.com/matrix-org/synapse.git
synced 2025-11-13 02:21:05 +00:00
Fix the type annotation on run_db_interaction in the Module API. (#16089)
* Fix the method signature of `run_db_interaction` on the module API * Newsfile Signed-off-by: Olivier Wilkinson (reivilibre) <oliverw@matrix.org> --------- Signed-off-by: Olivier Wilkinson (reivilibre) <oliverw@matrix.org>
This commit is contained in:
parent
efd4d06d76
commit
7f4b413690
1
changelog.d/16089.misc
Normal file
1
changelog.d/16089.misc
Normal file
@ -0,0 +1 @@
|
||||
Fix the type annotation on `run_db_interaction` in the Module API.
|
||||
@ -31,7 +31,7 @@ from typing import (
|
||||
|
||||
import attr
|
||||
import jinja2
|
||||
from typing_extensions import ParamSpec
|
||||
from typing_extensions import Concatenate, ParamSpec
|
||||
|
||||
from twisted.internet import defer
|
||||
from twisted.internet.interfaces import IDelayedCall
|
||||
@ -885,7 +885,7 @@ class ModuleApi:
|
||||
def run_db_interaction(
|
||||
self,
|
||||
desc: str,
|
||||
func: Callable[P, T],
|
||||
func: Callable[Concatenate[LoggingTransaction, P], T],
|
||||
*args: P.args,
|
||||
**kwargs: P.kwargs,
|
||||
) -> "defer.Deferred[T]":
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user