From 3646ca45a899dd22096246f77b451a2804b5917a Mon Sep 17 00:00:00 2001 From: Hashem Date: Mon, 16 Sep 2024 14:29:48 -0400 Subject: [PATCH] Add 'abandon_on_cancel' to to_thread.run_sync A new parameter name was added https://trio.readthedocs.io/en/stable/history.html#id15 And cancellable is now deprecated and causes a warning, so remote the old parameter name. --- trio-stubs/to_thread.pyi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trio-stubs/to_thread.pyi b/trio-stubs/to_thread.pyi index 570df91..766139d 100644 --- a/trio-stubs/to_thread.pyi +++ b/trio-stubs/to_thread.pyi @@ -10,6 +10,6 @@ def current_default_thread_limiter() -> trio.CapacityLimiter: ... async def run_sync( sync_fn: Union[Callable[..., _T], Callable[[VarArg()], _T]], *args: Any, - cancellable: bool = False, + abandon_on_cancel: bool = False, limiter: Optional[trio.CapacityLimiter] = None, ) -> _T: ...