Commit Graph

12 Commits

Author SHA1 Message Date
Sebastian Rittau
7a9a107a63 Move IdentityFunction to _typeshed (#5483)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2021-05-17 12:04:35 +02:00
Jon Dufresne
4166a416f6 Correct return type of click.testing.CliRunner.isolation() (#5103)
The method returns a tuple of io.BytesIO objects that hold the temporary
stdin and stdout. By correcting the type, it allows usages of
io.BytesIO.getvalue() to pass type checking.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2021-05-16 21:45:00 +02:00
Sebastian Rittau
6a4583d0a8 Deprecate pallets stubs (#5424)
Part of #5423

* Support new metadata fields in check_consistent
2021-05-12 19:17:42 +03:00
Giel van Schijndel
b0c6598fba fix(stubs/click): don't force autocompleter to accept anything as context (#5265)
* fix(stubs/click): don't force autocompleter to accept anything as context

Additionally it's enough if it's return value is iterable (e.g. a
generator).
2021-04-30 18:03:17 +03:00
Sebastian Rittau
4ac3ccad45 black: enable skip_magic_trailing_comma (#5252)
* black: enable skip_magic_trailing_comma

* Remove spurious commas
2021-04-27 08:32:32 -07:00
Sebastian Rittau
45916045c8 Upgrade black to 21.4b0 and reformat (#5250)
This introduces newlines before decorators.
2021-04-26 13:58:27 +02:00
Dominic Davis-Foster
a690a14c82 Annotate properties on exceptions in click.exceptions (#5232) 2021-04-19 18:20:43 +02:00
Jason Huang
087435ca65 fix(stubs/click): add the no_args_is_help argument annotaion for click (#5198) 2021-04-10 18:33:17 +03:00
Eric Traut
e2967a8bee Eliminated the use of "bare" TypeVars in stdlib stubs (#5041)
Eliminated the use of "bare" TypeVars (i.e. a TypeVar that appears only once) within generic methods. While not considered an error in PEP 484, these are a common source of bugs in code, and some type checkers (including pytype and pyright) flag them as errors.

Co-authored-by: Eric Traut <erictr@microsoft.com>
2021-02-27 19:43:45 -08:00
Eric Traut
4b4ced5fa0 Added missing type annotations and type arguments (#5070)
Co-authored-by: Eric Traut <erictr@microsoft.com>
Co-authored-by: Shantanu <hauntsaninja@users.noreply.github.com>
2021-02-25 15:09:58 -08:00
Ivan Levkivskyi
e2fd852952 Add more consistency tests (#4983)
Follow up fo #4971

Co-authored-by: Ivan Levkivskyi <ilevkivskyi@dropbox.com>
2021-01-29 17:23:35 +00:00
Ivan Levkivskyi
16ae4c6120 Re-organize directory structure (#4971)
See discussion in #2491

Co-authored-by: Ivan Levkivskyi <ilevkivskyi@dropbox.com>
2021-01-27 12:00:39 +00:00