From da4eeb29114bd8c38fc8143e0b891352dbc60c92 Mon Sep 17 00:00:00 2001 From: Antoine Lambert Date: Thu, 30 Jul 2026 18:06:26 +0200 Subject: [PATCH] [tqdm] Fix regression for contrib.concurrent in 4.70 stubs TypedDict describing optional keyword arguments must be declared non total or type checking is always failing. --- stubs/tqdm/tqdm/contrib/concurrent.pyi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/stubs/tqdm/tqdm/contrib/concurrent.pyi b/stubs/tqdm/tqdm/contrib/concurrent.pyi index 0d2db089baa9..44622ae76d36 100644 --- a/stubs/tqdm/tqdm/contrib/concurrent.pyi +++ b/stubs/tqdm/tqdm/contrib/concurrent.pyi @@ -52,19 +52,19 @@ class _TqdmCommonKwargs(TypedDict, total=False): # TODO: refactor this, when `TypedDict` will support conditional fields if sys.version_info >= (3, 14): @type_check_only - class _TqdmKwargs(_TqdmCommonKwargs): + class _TqdmKwargs(_TqdmCommonKwargs, total=False): buffersize: int | None else: _TqdmKwargs = _TqdmCommonKwargs @type_check_only -class _TqdmProcessKwargs(_TqdmKwargs): +class _TqdmProcessKwargs(_TqdmKwargs, total=False): mp_context: BaseContext | None max_tasks_per_child: int | None @type_check_only -class _TqdmThreadKwargs(_TqdmKwargs): +class _TqdmThreadKwargs(_TqdmKwargs, total=False): thread_name_prefix: str | None # Not techically for threading, but just a signature difference: lock_name: str