diff --git a/stubs/docopt/METADATA.toml b/stubs/docopt/METADATA.toml new file mode 100644 index 000000000000..c7567c225756 --- /dev/null +++ b/stubs/docopt/METADATA.toml @@ -0,0 +1,3 @@ +# Prior to v0.6, docopt() had only 3 optional args +version = "0.6" +python2 = true \ No newline at end of file diff --git a/stubs/docopt/docopt.pyi b/stubs/docopt/docopt.pyi new file mode 100644 index 000000000000..15c7f7d08cbc --- /dev/null +++ b/stubs/docopt/docopt.pyi @@ -0,0 +1,13 @@ +from typing import Any, Iterable, Optional, Union + +__version__: str + +_Argv = Union[Iterable[str], str] + +def docopt( + doc: str, + argv: Optional[_Argv] = ..., + help: bool = ..., + version: Optional[Any] = ..., + options_first: bool = ..., +) -> dict[str, Any]: ... # Really should be dict[str, Union[str, bool]]