Jelle Zijlstra
466f9c2ad7
redis: Fix unconstrained TypeVars in a few redis commands ( #7942 )
...
Part of #7928
2022-05-26 15:53:56 +01:00
Alex Waygood
fa636bc044
Third-party stubs: fix several fictitious type aliases ( #7958 )
2022-05-26 06:26:26 -07:00
Lee
597be79b18
markdown: annotate __deprecated__ ( #7955 )
2022-05-26 07:23:59 +01:00
Akuli
f77d0f80a8
requests: allow immutable headers ( #7932 )
2022-05-25 20:22:05 -07:00
Jaakko Lappalainen
773ddb15bb
Pillow: use union type for Image.paste (#7893 )
2022-05-25 10:04:59 +01:00
Jelle Zijlstra
796a689fc1
mock: Fix unconstrained TypeVar ( #7945 )
...
The first overload covers the case where `new` is not given.
Part of #7928
2022-05-25 06:52:40 +01:00
Jelle Zijlstra
070e6c2a2d
invoke: Fix unconstrained TypeVar ( #7943 )
...
Part of #7928
f34c6c9413/invoke/tasks.py (L328)
2022-05-25 06:48:49 +01:00
Jelle Zijlstra
bb119544d8
pkg_resources: Fix unconstrained TypeVars ( #7941 )
...
499c468a57/pkg_resources/__init__.py (L1049)
Part of #7928
2022-05-24 19:49:22 -07:00
Alex Waygood
54e11a1ec4
mypy_extensions: fix TypeVar usage (#7937 )
...
#7928
2022-05-24 11:26:35 -07:00
L
1e097a75cb
markdown: Annotate methods of Registry ( #7926 )
...
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com >
2022-05-24 10:23:48 -07:00
Rens Oliemans
6e18441a2c
Update emoji stubs for version 1.7 ( #7884 )
2022-05-22 11:44:01 +01:00
Peter Pentchev
ef887b7beb
More setuptools.command.easy_install definitions. ( #7145 )
...
Co-authored-by: Sebastian Rittau <srittau@rittau.biz >
Co-authored-by: Akuli <akuviljanen17@gmail.com >
2022-05-22 00:31:31 +03:00
eggplants
6d372ffc09
Add docopt.printable_usage ( #7913 )
2022-05-21 18:33:04 +02:00
David Robertson
e5594aac60
Annotations for psycopg2.ConnectionInfo ( #7834 )
...
* Annotations for psycopg2.ConnectionInfo
These annotations come from the documentation here:
https://www.psycopg.org/docs/extensions.html#psycopg2.extensions.ConnectionInfo
If there was doubt, I referred to the libpq documentation cited by
psycopg2's docs.
I wasn't completely sure about `dsn_parameters`. Psycopg2's docs list it
as an `dict`, and the example suggests it's a `dict[str, str]` at that.
From psycopg2's source I found
1d3a89a0bb/psycopg/conninfo_type.c (L183-L206)
which is implemented here:
1d3a89a0bb/psycopg/utils.c (L251-L279)
I'm no expert in CPython's API, but this looks to me like it's building
a `dict[str, str]`.
Additionally, the libpq docs
https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-PQCONNINFO
https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-PQCONNDEFAULTS
show that the underlying data just consists of strings.
Additionally, I'm pretty sure from this chunk of source
1d3a89a0bb/psycopg/conninfo_type.c (L581-L598)
That `ConnectionInfo.__init__` takes one positional-only argument, which
must be a `psycopg2.connection`. But I don't think users are intended to
be constructing this type, so I've not added that annotation.
* Annotate `connection.info` and related attributes
* Make ConnectionInfo attributes properties
According to 1d3a89a0bb/psycopg/conninfo_type.c (L534-L563)
* Mark connection attributes as readonly
according to 8ef195f2ff/psycopg/connection_type.c (L1244)
* Explain why some properties aren't `T | None`
2022-05-21 07:38:52 -07:00
Alex Waygood
76a4bd796b
Simplify and correct many numeric unions ( #7906 )
...
Unblocks PyCQA/flake8-pyi#222
2022-05-21 15:25:00 +01:00
Atsu Kakitani
d389b5f9cb
Import SQLAlchemy types in Flask-SQLAlchemy ( #7861 )
2022-05-19 08:19:49 +02:00
L
4a08afcbc2
markdown: Annotate parseBoolValue() ( #7875 )
2022-05-18 20:20:23 -07:00
Mehdi ABAAKOUK
f6c1383cae
reds: commands from asyncio module must be async ( #7820 )
...
redis-py has introduced an asyncio module since 4.2 and almost all
commands should be async if the redis.asyncio.Redis is used instead of
redis.Redis.
This changes adds the types for all core commands.
Related to #7597
2022-05-18 19:50:01 -07:00
Akuli
9a09db46f5
Fix requests.Session().hooks ( #7871 )
...
Fixes #7776
Mutating hooks, as in `session.hooks['response'] = ...`, should work. Reassigning it like `session.hooks = ...` is probably a bad idea, so it will always be a `dict`.
2022-05-18 19:31:34 -07:00
Eitan Mosenkis
f2f72d6c52
Add return type for dateutil.rrule._rrulestr.__call__. ( #7868 )
2022-05-18 22:57:38 +01:00
L
ada3615a24
markdown: Annotate code_escape(). ( #7857 )
2022-05-17 17:54:25 -07:00
Sebastian Rittau
a05ee9740d
Markdown: use I/O protocols ( #7851 )
2022-05-17 15:00:59 +02:00
L
81be86af6e
markdown: Annotate Registry.get_index_for_name() ( #7848 )
2022-05-17 11:48:55 +02:00
Alejandro Giacometti
87abd8a39f
requests: Fix type of request headers (#7773 )
...
Allow bytes values. In `Session` methods, `None` can be used to ignore the session's headers.
2022-05-16 23:33:46 +03:00
L
487bef5a67
markdown: isBlockLevel() returns a bool value. ( #7839 )
2022-05-16 15:52:22 +02:00
Sam Bull
686cd6ef63
Add __version__/VERSION to redis ( #7838 )
2022-05-15 11:55:12 +01:00
L
dbccdcb50e
markdown: @deprecated argument of message is a str. ( #7835 )
2022-05-12 18:48:20 -07:00
L
f8db698ece
markdown: PY37 is a bool ( #7831 )
2022-05-11 19:46:50 -07:00
Jelle Zijlstra
b00b4f3447
regex: accept buffers ( #7680 )
...
Similar to #7679
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com >
Co-authored-by: Akuli <akuviljanen17@gmail.com >
2022-05-10 15:08:36 -07:00
Alex Waygood
fed1f35c32
Remove explicit inheritance from object ( #7819 )
2022-05-10 16:24:53 +03:00
Sebastian Rittau
b211bf31a3
Update testing_engine() annotations ( #7818 )
2022-05-10 12:46:01 +03:00
Shantanu
550454c9aa
beautifulsoup4: small fixes and updates ( #7816 )
2022-05-10 09:17:40 +02:00
Alex Waygood
ac30b96d14
Use str instead of Text ( #7812 )
2022-05-09 20:47:11 +01:00
Julian
032d937bdf
#7805 : Ensure all references to mode are Literals, not str. ( #7807 )
2022-05-08 16:51:27 +02:00
Alex Waygood
5c6178a821
Import generics from standard modules in all third-party stubs ( #7791 )
2022-05-07 10:35:50 +02:00
Shantanu
e8b361983f
bs4: update to 4.11 ( #7785 )
...
Co-authored-by: hauntsaninja <>
2022-05-06 11:54:50 -07:00
Ilya Konstantinov
0b5213a213
flask-cors.decorator: allow re.Pattern objects to origins and allow_headers parameters (#7782 )
2022-05-06 19:34:51 +01:00
kasium
92c578546a
Improve types of invoke/env.pyi ( #7780 )
2022-05-05 07:12:51 +01:00
Sebastian Rittau
460537c7f6
Add missing redis modules and classes ( #7676 )
...
This adds asyncio support and support for redis.typing.
2022-05-04 11:29:13 +02:00
Shantanu
4bcb1a95ab
Upgrade paramiko ( #7766 )
2022-05-02 20:52:14 +02:00
Jovan Bebic
f05bfe0315
Fix paramiko channel.setblocking() argument ( #7758 )
...
Add 0,1 as allowed arguments using `Literal[0,1]`
2022-04-30 15:15:36 -06:00
Akuli
e613fc483b
Delete python 2 branches from third-party stubs ( #7741 )
...
Since #7703 , we no longer have third-party stubs that support Python 2, so code like `if sys.version_info >= (3, 0)` can be simplified.
2022-04-29 20:53:01 +01:00
Sebastian Rittau
5535b7fc08
Update caldav stubs for 0.9 ( #7734 )
2022-04-28 17:56:43 +03:00
Milan Boers
f330e12f3e
requests: allow non-mutable Mapping for files/hooks parameters ( #7732 )
2022-04-28 08:40:53 -06:00
Milan Boers
df06044ee8
requests: allow str and bytes for fileobj in files parameter ( #7728 )
...
* requests: allow str and bytes for fileobj in files parameter
* requests: Use SupportsRead instead of IO for files
2022-04-28 02:19:57 -06:00
Alex Waygood
59c346d031
cryptography: make oid attributes readonly ( #7731 )
2022-04-28 00:58:49 -06:00
Jelle Zijlstra
1deb9cb806
jack: Fix MidiPort properties ( #7730 )
...
Fixes #7729
26b648a361/src/jack.py (L1950)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com >
2022-04-27 22:28:17 -06:00
Alec Rosenbaum
63fb9af743
requests: Add None to a type alias ( #7721 )
...
Fixes #7720
2022-04-27 08:39:15 -06:00
Sebastian Rittau
ff2feff7df
dateutil.tz.tz: Replace IO with protocols ( #7717 )
2022-04-27 16:37:57 +03:00
Sebastian Rittau
f7aa41245e
Drop Python 2 support in third-party stubs ( #7703 )
2022-04-27 15:32:17 +03:00