Sebastian Rittau
fdeae5d00e
Enable --disallow-subclassing-any ( #3591 )
...
Closes : #1446
2020-01-08 11:51:44 -08:00
rikhilraithatha
caca02b096
redis: add ping to PubSub ( #3583 )
2020-01-07 17:20:43 +01:00
Daniel Hahler
89c598f7c9
jinja2: add Template.{name,filename} ( #3578 )
...
Ref::
- https://jinja.palletsprojects.com/en/2.10.x/api/#jinja2.Template.name
- https://jinja.palletsprojects.com/en/2.10.x/api/#jinja2.Template.filename
2020-01-05 17:58:56 -08:00
Christopher Dignam
bd14fcaaa6
requests: type responses for PreparedRequest ( #3577 )
2020-01-06 00:27:21 +01:00
Pavel Savchenko
616b6d0f3b
Add missing definitions to requests.utils ( #3567 )
...
Added:
+ DEFAULT_PORTS
+ extract_zipped_paths
+ select_proxy
+ rewind_body
2020-01-05 16:07:36 +01:00
Mickaël Schoentgen
b4d1da03aa
Add missing Path.is_mount() introduced in Python 3.7 ( #3566 )
2020-01-05 16:04:52 +01:00
Jeppe Fihl-Pearson
fed3472e7c
Reflect Python 3.8 updates to the pathlib stdlib module ( #3568 )
2020-01-03 08:47:50 -08:00
Artjoms Iskovs
61f139189e
Fix RSAPublicNumbers stub ( #3505 )
...
`RSAPublicNumbers` is supposed to have an exponent `e` and modulus `n` instead of `p` and `q` (typo?)
2019-12-21 12:38:16 -08:00
abe
f7119c30ce
Update stubs for Crypto.Random ( #3546 )
2019-12-19 22:26:51 +01:00
Jacob Beck
9d61baa7be
add jinja macro fields ( #3548 )
2019-12-18 18:56:06 +01:00
Brian Maissy
c0c780a758
add a couple missing stubs and fix an incorrect return type for redis stubs ( #3545 )
2019-12-18 07:49:19 +01:00
Dylan Anthony
9b63192390
Update orjson stub from orjson repository( #3532 )
2019-12-06 15:59:27 +01:00
toppk
86775c803e
Minor fixes to cryptography (x509) ( #3520 )
2019-12-03 18:29:05 +01:00
toppk
b585c96e5d
padding can take an int or an object (PSS.MAX_LENGTH) ( #3521 )
2019-12-03 13:26:16 +01:00
Katelyn Gigante
e8647d2d1d
A few return annotations for redis client ( #3517 )
2019-12-02 21:06:11 -08:00
Ivan Levkivskyi
8df632bca5
Fix some issues in cryptography package ( #3474 )
...
Note: the verifier() methods are not in docs, but they don't look private and are actually used in some code.
2019-11-21 17:05:22 +00:00
Sebastian Rittau
79d4e0dd08
Add assorted werkzeug type hints ( #3444 )
...
* Annotate is_immutable()
* Annotate ImmutableListMixin and make generic
* Make ImmutableList generic and derive from generic List
* Annotate Accept
* Annotate MIMEAccept
* Fix annotation of parse_accept_header()
2019-11-06 10:37:18 -08:00
Markus Bauer
f39c102eb8
Add more stubs to redis (pubsub and monitor) ( #3442 )
2019-11-06 12:05:51 +01:00
Jeremy Lainé
047caa9096
Add more stubs for cryptography ( #3307 )
2019-11-04 12:41:11 +01:00
Jon Dufresne
66c3945ca4
Remove certifi.old_where ( #3436 )
...
The function was removed from the API in commit (Nov 26, 2018):
a462d21c3f
2019-11-03 18:26:43 +01:00
Greg Ward
603458ba09
Fix some incorrect/incomplete annotations for redis.client.PubSub ( #3408 )
...
* redis: Fix return value declarations in redis.client.PubSub
get_message() was declared incorrectly. Start here:
https://github.com/andymccurdy/redis-py/blob/3.3.11/redis/client.py#L3298-L3300
where it's obvious that get_message() returns either None or the
output of handle_message().
So what does handle_message() return? Combine:
https://github.com/andymccurdy/redis-py/blob/3.3.11/redis/client.py#L3316-L3336
https://github.com/andymccurdy/redis-py/blob/3.3.11/redis/client.py#L3366
and you can see it returns None or a dict mapping str to something.
* redis: Fix incorrect declaration for PubSub.get_message() argument
Docstrings says it's a float:
https://github.com/andymccurdy/redis-py/blob/3.3.11/redis/client.py#L3293-L3295
And it eventually gets passed to settimeout() on a socket:
https://github.com/andymccurdy/redis-py/blob/3.3.11/redis/connection.py#L182
* redis: Annotate one more method arg in PubSub class
get_message() and handle_message() are closely related:
ignore_subscribe_message does the same in both, and its default value
in both is False.
2019-10-30 07:33:00 -07:00
Angela Ambroz
b5b9a3959d
Add pytz.FixedOffset ( #3393 )
2019-10-29 19:50:20 -07:00
Dima Boger
aae01b8de0
Add sort_keys param to all dump-like functions in PyYAML (yaml) lib ( #3417 )
2019-10-29 19:44:04 -07:00
Taneli Hukkinen
beaf306d12
Allow None for click.core.Context.default_map ( #3416 )
2019-10-29 00:10:27 +01:00
Utkarsh Gupta
72ff7b94e5
__init__.pyi: Accept RSAPrivateKey or RSAPublicKey as the key ( #3410 )
...
Closes : #3381
2019-10-26 21:09:06 +02:00
Ilaï Deutel
bf944dbf94
Update stubs for tabulate ( #3391 )
2019-10-24 20:19:08 -07:00
Anthony Sottile
9feb21d029
Add werkzeug.exceptions.FailedDependency ( #3403 )
...
Available since werkzeug==0.15.0
2019-10-24 00:14:52 +02:00
Sebastian Rittau
ec7960a8cb
Convert namedtuples to class syntax ( #3321 )
2019-10-20 10:37:33 +02:00
JR Heard
bf862d9079
Add missing @property to Response.next() stub ( #3384 )
2019-10-18 10:23:15 +02:00
David Tucker
38fbdc9490
Fix show_default type in click.option signatures ( #3385 )
2019-10-18 10:22:02 +02:00
Trim21
6b68fb04c9
pymysql.Cursor is a context manager ( #3379 )
2019-10-17 15:01:55 +02:00
Jakub Stasiak
6e4f6403ac
Add PEP 593 (Annotated etc.) typing_extensions stubs ( #3369 )
...
The code has been added to typing_extensions in
https://github.com/python/typing/pull/632 and
https://github.com/python/typing/pull/639/ .
2019-10-16 11:41:38 -07:00
Benjamin Peterson
add16d2715
protobuf: Fix inadvertently deleted annotations. ( #3364 )
...
* protobuf: Fix inadvertantly deleted annotations.
* Run black on protobuf.
2019-10-14 13:41:58 -07:00
Sebastian Rittau
0501e2b329
Annotations for remaining Python 3.8 additions ( #3358 )
...
* Add os.add_dll_directory()
* Add memfd_create() and flags
* Add type annotation to flags
* Add stat_result.st_reparse_tag and flags
* Add ncurses_version
* Add Path.link_to()
* Add Picker.reducer_override()
* Add plistlib.UID
* Add has_dualstack_ipv6() and create_server()
* Add shlex.join()
* Add SSL methods and fields
* Add Python 3.8 statistics functions and classes
* Remove obsolete sys.subversion
* Add sys.unraisablehook
* Add threading.excepthook
* Add get_native_id() and Thread.native_id
* Add Python 3.8 tkinter methods
* Add CLOCK_UPTIME_RAW
* Add SupportsIndex
* Add typing.get_origin() and get_args()
* Add unicodedata.is_normalized
* Add unittest.mock.AsyncMock
Currently this is just an alias for Any like Mock and MagicMock. All of
these classes should probably be sub-classing Any and add their own
methods. See also #3224 .
* Add unittest cleanup methods
* Add IsolatedAsyncioTestCase
* Add ElementTree.canonicalize() and C14NWriterTarget
* cProfile.Profile can be used as a context manager
* Add asyncio task name handling
* mmap.flush() now always returns None
* Add posonlyargcount to CodeType
2019-10-14 09:53:48 +02:00
Benjamin Peterson
036abc7fda
protobuf: Narrow type of Message.FromString. ( #3340 )
...
Remove unnecessary definitions in sub-classes.
2019-10-11 08:28:28 +02:00
Benjamin Peterson
fc23c8274f
protobuf: Tighten annotations for MergeFromString and ParseFromString. ( #3333 )
2019-10-10 18:07:53 +02:00
Jukka Lehtosalo
eca93753ee
Update the signature of decorator.decorator ( #3336 )
...
Nothing prevents a decorator defined using `@decorator` from
changing the signature of the decorated function. For example,
this example changes the return type to `str`:
```
from decorator import decorator
@decorator
def stringify(f, *args, **kwargs) -> str:
return str(f(*args, **kwargs))
```
The old signature caused false positives in internal Dropbox code.
I couldn't come up with a signature that would produce better types
with mypy while not generating false positives.
2019-10-10 16:45:06 +01:00
Vasily Zakharov
57384ce033
Revised stubs for geoip2 third party library ( #3317 )
2019-10-09 19:28:42 -07:00
Sebastian Rittau
07c8675ba5
Remove unused # type: ignore comments ( #3325 )
2019-10-09 10:27:18 -07:00
Utkarsh Gupta
bd7222c396
models.pyi: Add missing requests.Respons.next() ( #3328 )
...
Closes : #3207
2019-10-09 19:01:30 +02:00
Jukka Lehtosalo
3a2fdfd45d
Make it explicit that the cryptography stubs are incomplete ( #3331 )
2019-10-09 16:20:36 +01:00
Jukka Lehtosalo
0914d50b49
Fix the signature of decorator.contextmanager ( #3330 )
2019-10-09 16:58:37 +02:00
Benjamin Peterson
50961d45a1
protobuf: Add Message.FromString static method. ( #3327 )
2019-10-09 07:59:07 +02:00
Utkarsh Gupta
4027add6b3
__init__.pyi: Add missing methods on pkg_resources.VersionConflict ( #3318 )
2019-10-08 20:36:38 +02:00
Sebastian Rittau
256b3ce8ab
Remove a bunch of unused imports ( #3323 )
2019-10-08 07:59:32 -07:00
Lukáš Lalinský
a6f146e651
Fix return type of werkzeug's ProxyFix ( #3320 )
2019-10-08 10:30:00 +02:00
Rafi Blecher
6e4708ebf3
Add type stub for decorator lib ( #3038 )
2019-10-07 22:21:31 +02:00
Glyph
83589844c9
rrule.weekday(...) returns rrule.weekdays, not _common.weekdays. ( #3274 )
2019-10-05 01:49:49 +02:00
Sebastian Rittau
0a426d8a8e
Move cryptography from 2 to 2and3 ( #3304 )
...
The cryptography stubs are very rudimentary at the moment, but there
is nothing that limits them to just Python 2.
Closes : #3303
2019-10-04 14:11:42 -07:00
Vasily Zakharov
e62857f851
Updated maxminddb stubs to v1.5.0 ( #3300 )
2019-10-04 12:55:46 +02:00