diff options
author | danieleades <33452915+danieleades@users.noreply.github.com> | 2022-07-18 22:08:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-18 22:08:16 +0100 |
commit | a504ac6100a577cbda1bedf80d69636603ee287c (patch) | |
tree | 0aa79585440486bdb109f7238f8f5c992dad0d99 /sphinx/util/parallel.py | |
parent | a340427ba4d208193d539cb7e8401be23d75547e (diff) | |
download | sphinx-git-a504ac6100a577cbda1bedf80d69636603ee287c.tar.gz |
Improve static typing strictness (#10569)
Diffstat (limited to 'sphinx/util/parallel.py')
-rw-r--r-- | sphinx/util/parallel.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sphinx/util/parallel.py b/sphinx/util/parallel.py index 193d2a80d..e89418ad3 100644 --- a/sphinx/util/parallel.py +++ b/sphinx/util/parallel.py @@ -81,7 +81,9 @@ class ParallelTasks: logging.convert_serializable(collector.logs) pipe.send((failed, collector.logs, ret)) - def add_task(self, task_func: Callable, arg: Any = None, result_func: Callable = None) -> None: # NOQA + def add_task( + self, task_func: Callable, arg: Any = None, result_func: Optional[Callable] = None + ) -> None: tid = self._taskid self._taskid += 1 self._result_funcs[tid] = result_func or (lambda arg, result: None) |