Jakob Stadler and GitHub
d6403b14aa
stdlib: Fix os.startfile ( #10996 )
...
Fixes #10991
2023-11-08 15:44:14 -08:00
Jelle Zijlstra and GitHub
17f8a82376
ast: mark ast.Num etc. as deprecated ( #10994 )
2023-11-08 19:40:22 +01:00
Alex Waygood and GitHub
516f665505
Bump flake8-pyi to 23.11.0 ( #10997 )
2023-11-08 16:01:24 +00:00
Jelle Zijlstra and GitHub
b36f3c5229
asyncio: remove overly specific protocols ( #10984 )
...
The _warn parameter to these methods is just there to work around
some finalization issues and should never be used by users. In
addition, these protocols are out of date (the "stacklevel" argument
is not used by current CPython main). I don't think we gain anything
by trying to maintain these protocol definitions.
2023-11-07 19:26:25 -08:00
Thomas M Kehrenberg and GitHub
359d4c095d
Fix return type of dbm.whichdb ( #10989 )
...
It is `None` if the given file doesn't exist or isn't a database.
2023-11-07 12:49:39 +01:00
Jelle Zijlstra and GitHub
3229b36644
stdlib: More pos-only parameters to Protocols ( #10987 )
2023-11-06 23:45:12 +01:00
Jelle Zijlstra and GitHub
5030b7419b
stdlib: Use pos-only parameters for many Protocols ( #10985 )
2023-11-06 18:09:04 +01:00
Sebastian Rittau and GitHub
a5c1a4cd3f
Introduce _typeshed.SupportsFlush ( #10983 )
2023-11-06 15:31:02 +01:00
Andrey Rakhmatullin and GitHub
7b18a0be91
Fix type hint for xml.sax.saxutils.XMLGenerator.__init__(). ( #10979 )
...
The `out` parameter accepts objects with `write(__o: bytes)`, not `write(__o: str)` methods.
2023-11-06 14:31:50 +01:00
Alex Waygood and GitHub
8023ba764a
Remove redundant inheritances from Generic and various typing protocols ( #10981 )
2023-11-06 14:00:25 +01:00
Tin Tvrtković and GitHub
c8073493fc
http.HTTPConnection.putheader tweak ( #10978 )
2023-11-05 15:38:41 -08:00
Avasam and GitHub
3a56e0034c
xml.etree: Fix tag param in __init__ ( #10968 )
2023-11-03 14:50:49 +01:00
Serious-senpai and GitHub
fa088948aa
Fix incorrect typehint for callbacks in multiprocessing.Pool ( #10949 )
2023-11-02 16:59:29 +01:00
3c872ca8fd
Add types to some tkinter.Text methods. ( #10946 )
...
Co-authored-by: Akuli <akuviljanen17@gmail.com >
2023-10-31 18:44:39 +02:00
Benedikt Radtke and GitHub
1196915b39
fix nullability of scrypt params ( #10942 )
2023-10-29 01:35:39 +02:00
Alex Waygood and GitHub
56288ad2d0
Add stubs for importlib.(resources.)simple ( #10931 )
2023-10-28 07:29:57 -07:00
Avasam and GitHub
49ba409da8
Replace isort with Ruff ( #10912 )
2023-10-27 20:14:38 -07:00
Alex Waygood and GitHub
77bccbe1f1
sys.monitoring.restart_events() is no longer undocumented (#10938 )
...
Following https://github.com/python/cpython/commit/3f84a19e6291db682fc9a570e7612e80e2ffbbb5
2023-10-27 17:14:54 +01:00
Sebastian Rittau and GitHub
1c184fea33
Simplify Traversable signature ( #10934 )
...
Simplify Traversable.open() signature. This is necessary so that implentors can
reasonanbly implement this method. For example `zipfile.Path.open()` (which
is considered a `Traversable`) only supports this subset.
Make `Traversable.__truediv__` and `joinpath` arguments pos-only. The
arguments are named differently in both `pathlib.Path` and `zipfile.Path`.
2023-10-27 00:50:11 +02:00
Alex Waygood and GitHub
a08d4c8d2e
Remove many redundant inheritances from Generic[] ( #10933 )
2023-10-26 20:07:20 +02:00
Alex Waygood and GitHub
5dbdd59c9b
Add io.text_encoding on py310+ ( #10929 )
...
See https://discuss.python.org/t/type-checkers-complain-about-io-text-encoding/37187/1 for discussion. The function is documented, even though it's not included in `io.__all__` (which is why stubtest hasn't been complaining about it being missing): https://docs.python.org/3/library/io.html#io.text_encoding
2023-10-26 10:41:31 -07:00
908993a807
Add stubs for importlib.(resources.)readers ( #10928 )
...
Co-authored-by: Sebastian Rittau <srittau@rittau.biz >
2023-10-26 14:18:55 +01:00
Aditya Paul and GitHub
2ce9dcd5fb
Allow str for tkinter.Scrollbar.set() ( #10926 )
2023-10-25 20:48:08 +03:00
Viicos and GitHub
78fba20110
Make inspect.getblock more ergonomic for common input types ( #10920 )
2023-10-25 12:58:11 +01:00
Nikita Sobolev and GitHub
5c775a3502
Improve int.__pow__ and float.__pow__ comments ( #10925 )
...
It used to be `__x`. Now, it is not clear what `x` is in this context.
2023-10-25 10:15:34 +01:00
Alex Waygood and GitHub
b9640005eb
Add stubs for nt ( #10917 )
2023-10-19 10:16:06 -07:00
Avasam and GitHub
35873ec3d8
Doc: Use proper name capitalization of tooling (Ruff, Black, Flake8) ( #10913 )
2023-10-18 23:46:53 +01:00
d14c5f82c8
Bump pyright to 1.1.332 ( #10904 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com >
2023-10-18 10:09:50 +01:00
838dd3a5ba
Add sys.monitoring from Python 3.12 ( #10890 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com >
2023-10-16 13:50:06 +01:00
Alex Waygood and GitHub
f3506eba47
Bump various test dependency pins ( #10877 )
2023-10-13 13:07:52 +02:00
Sebastian Rittau and GitHub
3632fc225c
Extend and fix zipfile ( #10861 )
...
* Add `CompleteDirs` and `FastLookup` (Python 3.8+).
* Add `Path.root` (Python 3.8+).
* Use concrete signature for `Path.open()` (Python 3.8).
* Fix signature of `Path.open()` for Python 3.9+:
+ Add overloads for text and binary modes with fixed return types.
+ Disallow extra arguments for binary modes.
+ Replace `*args` and `**kwargs` with accepted arguments for
text modes.
Closes : #10847
2023-10-08 06:30:51 -07:00
Alex Waygood and GitHub
c47be697a3
locale: put all the imports together at the top (#10860 )
2023-10-08 14:18:27 +02:00
Nikita Sobolev and GitHub
5531e9d470
Add _locale module ( #10859 )
...
More accurately reflect the platform availability of several constants and functions in `locale`.
2023-10-08 12:55:19 +02:00
Alex Waygood and GitHub
e4edcf23e0
Fix platform availability of some Unix constants ( #10857 )
2023-10-07 15:05:20 -07:00
Nikita Sobolev and GitHub
8acf1944f3
Remove allowlist entries for _ctypes on win ( #10855 )
2023-10-07 21:43:33 +02:00
Nikita Sobolev and GitHub
fb994e344b
Fix ssl.SSLSocket methods on windows ( #10849 )
2023-10-07 07:50:52 +01:00
Nikita Sobolev and GitHub
48d4f7a6a5
Add winreg.HKEYType.handle property ( #10848 )
2023-10-06 19:20:12 +01:00
Nikita Sobolev and GitHub
a12b2053cd
Add SetErrorMode to msvcrt module ( #10842 )
2023-10-05 22:06:11 +01:00
James Hilton-Balfe and GitHub
25eb99cbec
Add better types for asyncio.gather ( #9678 )
2023-10-04 10:10:41 +01:00
Nikita Sobolev and GitHub
cc5b3f8bc4
Fix platform availability of some os/posix constants ( #10831 )
2023-10-03 15:20:00 +01:00
860e34eec9
Fix allowlist entries in asyncio.windows_events ( #10824 )
...
And fix the return value of return value of `IocpProactor.recvfrom_into()`, which was incorrect
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com >
2023-10-02 16:04:11 +01:00
Alex Waygood and GitHub
54d825af59
Fix Windows-specific allowlist entries in _msi, msilib, selectors and subprocess ( #10822 )
2023-10-02 13:01:47 +02:00
Nikita Sobolev and GitHub
07e611d41f
select.POLLRDHUP does not exist on macos (#10823 )
2023-10-02 11:59:29 +01:00
Nikita Sobolev and GitHub
66d183fc56
mimetypes.MimeTypes.read_windows_registry always exists (#10821 )
2023-10-02 11:35:48 +01:00
Nikita Sobolev and GitHub
b3b5661f80
Add DefaultSelector.fileno on platforms where it exists ( #10820 )
2023-10-02 11:15:49 +01:00
Alex Waygood and GitHub
205cfcfca6
Fix availability of some constants for Windows ( #10818 )
2023-10-01 16:27:55 -07:00
Alex Waygood and GitHub
efa7a51d09
Add a few missing things on Windows, py310+ ( #10817 )
2023-10-01 23:30:44 +01:00
bzoracler and GitHub
3eb9ff7f65
fix __match_args__ attribute name ( #10813 )
2023-10-01 07:51:02 -07:00
Nikita Sobolev and GitHub
bd4462cc62
Re-export SYSPROTO_CONTROL and PF_SYSTEM in socket on macos ( #10814 )
2023-10-01 15:38:44 +01:00
460fa14dfc
Fix curses.color_pair signature ( #10811 )
...
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com >
2023-09-30 20:58:37 +01:00