Skip to content

Commit 58367a5

Browse files
[click-web] Fixes after click 8.2.0 release (#14001)
1 parent c4aa48a commit 58367a5

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

stubs/click-web/click_web/__init__.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ OUTPUT_FOLDER: str
1313
_flask_app: flask.Flask | None
1414
logger: logging.Logger | None
1515

16-
def create_click_web_app(module: types.ModuleType, command: click.BaseCommand, root: str = "/") -> flask.Flask: ...
16+
def create_click_web_app(module: types.ModuleType, command: click.Command, root: str = "/") -> flask.Flask: ...

stubs/click-web/click_web/resources/input_fields.pyi

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import sys
12
from typing import Any, ClassVar, Final
23

34
import click
@@ -46,7 +47,10 @@ class BaseInput:
4647
def _build_name(self, name: str): ...
4748

4849
class ChoiceInput(BaseInput):
49-
param_type_cls: type[click.Choice]
50+
if sys.version_info >= (3, 10):
51+
param_type_cls: type[click.Choice[Any]]
52+
else:
53+
param_type_cls: type[click.Choice]
5054

5155
class FlagInput(BaseInput):
5256
param_type_cls: None

0 commit comments

Comments
 (0)