Commit Graph

30 Commits

Author SHA1 Message Date
Jelle Zijlstra
eab82c838a asyncio: updates for 3.11 (#7844)
CPython changes:

- 13c10bfb77
- 9523c0d84f
- 9f04ee569c
- d03acd7270
- 195a46d6ff

Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2022-05-17 18:11:29 -07:00
Sebastian Rittau
499e74cf2a Add wsgiref.types (Python 3.11+) (#7644)
_typeshed.wsgi: Import from wsgiref.types in Python 3.11+

Make types match wsgiref.types
2022-04-16 21:36:31 +02:00
Taneli Hukkinen
31b11c6eae Add type hints for tomllib (#7432) 2022-03-03 15:04:33 -08:00
Alex Waygood
07de01f29e Add __all__ to modules beginning with 'm' (#7330) 2022-02-20 14:08:07 -08:00
Guido van Rossum
35bddd289f Add asyncio.taskgroups and new Task methods (#7240)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-02-17 00:32:20 +02:00
Alex Waygood
5a8b9dafb3 Fix various py310 stubtest errors (#7239) 2022-02-16 11:47:49 -08:00
Nikita Sobolev
bfda5c640b Add mixins module to asyncio (#6789) 2022-01-25 12:53:55 +01:00
Alex Waygood
7d33ff330a Clean up several version-dependent modules (#6885) 2022-01-10 05:57:08 -08:00
Alex Waygood
84fd495b65 Update importlib to reflect recent changes (#6557) 2021-12-10 14:32:55 +01:00
Akuli
b3e8073bac Create unittest._log stub and improve _AssertLogsContext (#6428)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2021-11-30 21:39:14 -08:00
Shantanu
c47ed98b3e dummy_thread/ing: remove in 3.9 (#6408)
https://bugs.python.org/issue37312
2021-11-27 20:50:14 -08:00
Alex Waygood
9707cb00f6 Python 3.11 removals in stdlib (#6374)
Co-authored-by: Akuli <akuviljanen17@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2021-11-25 19:34:12 +02:00
Shantanu
8576b344b8 binhex: removed in py311 (#6011) 2021-09-10 15:27:24 -07:00
Akuli
200260e685 move DndSource to tkinter/dnd.pyi (#5588) 2021-06-07 07:07:57 -07:00
Rebecca Chen
a4075472d3 Add some submodule versions to stdlib/VERSIONS. (#5573)
Adds some version ranges for submodules that are available in different
versions that their parent modules.

I noticed these while updating pytype's pinned typeshed commit. pytype
can't actually use this submodule version information yet, but from what
I understand, all type checkers at least handle this information
gracefully (by ignoring it), so it doesn't hurt to add it.

* collections.abc is available in Python 3.3 and later. _collections_abc
  is imported by the collections.abc stub, so its version range is also
  changed from 3.6- to 3.3-.
* _typeshed.tkinter needs to be 3.0-, since it imports tkinter, which is
  marked as 3.0-.
* importlib.metadata is available in 3.8 and later.
2021-06-03 18:15:47 -07:00
Sebastian Rittau
6ee67483a3 Rework socket (#5545)
* Extract _socket.pyi from socket.pyi.
* Extract _socket.socket from socket.socket.
* Fix socket.family annotation.
* Annotate SocketIO properly.
* SocketType is an alias of _socket.socket.
* Sort items in socket.pyi in the same order as in socket.py.
* Remove socket.EINTR.
* Use _typeshed.WriteableBuffer instead of custom alias.
* Add errorTab (Windows only).
* Add _socket.dup().
* Mark positional-only argments.
* Remove constructors from socket exceptions.
* socket.timeout is an alias for TimeoutError, starting with Python 3.10.
* Use PEP 604 in changed lines.
* Add alias for fileno arguments.
* getaddrinfo() port can be bytes.
* Explicitly override some SSLSocket methods.
* Allow ReadableBuffer in _CMSG arguments.
2021-05-30 20:17:33 +02:00
Jukka Lehtosalo
e5459900c0 Make html, ipaddress, reprlib and winreg only available on Python 3 (#5502)
None of these are available in Python 2.7.
2021-05-19 12:16:10 +01:00
Sebastian Rittau
54a0bd80ee Add a comment about _typeshed to VERSIONS (#5447) 2021-05-19 11:01:33 +02:00
Sebastian Rittau
dbe77b6ae9 importlib.resources was added in 3.7 (#5468)
Describe sub-module versioning
2021-05-16 07:04:28 -07:00
Jelle Zijlstra
a47ee3245a fix renamed Python 2 modules (#5450) 2021-05-14 14:36:00 -07:00
Sebastian Rittau
322396bb32 configparser available since Python 3.0 (#5443)
It was called ConfigParser in Python 2.

Split out from #5442.
2021-05-14 05:24:50 -07:00
Sebastian Rittau
d98fdd934c Move VERSIONS description to file itself (#5434) 2021-05-13 06:14:44 -07:00
Sebastian Rittau
1eb64b4372 Mark stdlib modules with upper version bounds (#5394)
* Mark stdlib modules with upper version bounds

* Add minus to all versions and enforce in check_consistent

* Fix check_consistent and mypy_test to work with new VERSIONS format
2021-05-10 16:29:43 +03:00
Jelle Zijlstra
5f591a1a12 fix VERSIONS (#5329) 2021-05-07 08:43:22 +02:00
Akuli
97101b1d2c create stub for __main__ (#5354)
* create stub for __main__

* exclude from pyright, like all other __getattr__ incomplete stubs
2021-05-06 18:57:33 +03:00
Akuli
e66b7fa660 delete _importlib_modulespec (#5350)
* delete _importlib_modulespec

* use typing_extensions.runtime_checkable
2021-05-06 17:13:35 +03:00
Shantanu
fc660d6d41 Move typing_extensions to stdlib (#5233)
I'm not sure what the best way to do this is. This effectively orphans
types-typing-extensions, but maybe that's not really a problem. (We can
yank the package too)

See https://github.com/python/typeshed/pull/5229#issuecomment-822234125
for some details

Co-authored-by: hauntsaninja <>
2021-04-20 21:55:48 -07:00
Sebastian Rittau
0cea325bc7 Modernize logging (#5068) 2021-03-22 19:26:43 -07:00
Sebastian Rittau
08b26b9e8e Split and restore correct Python 2 version of cgi.pyi (#5064)
* Split cgi.pyi into Py2 and 3 versions

* Restore correct Python 2 version of cgi.pyi

* Remove unnecessary version checks in cgi.pyi

* Use collections.abc

* Use List in Python 2 stub
2021-02-24 14:46:03 -08: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