Commit Graph

32 Commits

Author SHA1 Message Date
tungol
1b6691067a fix superclass for UnixDatagramServer and UnixStreamServer (#11115) 2023-12-07 08:05:46 +01:00
Nikita Sobolev
e5651db430 Update socketserver for Python3.12 (#10246)
Source: https://github.com/python/cpython/blob/3.12/Lib/socketserver.py
2023-06-03 13:53:51 +01:00
Alex Waygood
1d2ae2598b Fix some typos in comments (#9802) 2023-02-23 22:11:24 +00:00
Alex Waygood
6ba28ae547 Remove unused type: ignore comments (#9801) 2023-02-23 12:59:50 -08:00
Alex Waygood
3786ab295e Fix an unnecessary socketserver allowlist entry (#9777) 2023-02-20 11:14:20 -08:00
Alex Waygood
9ed39d8796 Use typing_extensions.Self in the stdlib (#9694) 2023-02-09 09:12:13 +00:00
Alex Waygood
0ef9c3f8e8 Enable flake8-pyi's Y037 (#9686) 2023-02-06 19:01:02 -08:00
Alex Waygood
33a62ae42d Add more defaults to the stdlib (#9606)
Continuing work towards #8988.

The first five commits were created using stubdefaulter on various Python versions; the following commits were all created manually by me to fix various problems. The main things this adds that weren't present in #9501 are:

- Defaults in Windows-only modules and Windows-only branches (because I'm running a Windows machine)
- Defaults in non-py311 branches
- Defaults for float parameters
- Defaults for overloads
2023-01-29 01:51:23 +00:00
Jelle Zijlstra
ddfaca3200 stdlib: add argument default values (#9501) 2023-01-18 09:37:34 +01:00
Jelle Zijlstra
f64807a468 socketserver: improve bytes handling (#9096)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-01-12 16:46:20 +00:00
Nikita Sobolev
0259068ad6 Remove duplicate definitions in sub-classes (#8594) 2022-08-26 17:10:55 +02:00
Peter Law
3623f923a6 Fix UDPServer to correctly inherit from TCPServer (#8542) 2022-08-13 19:03:59 +02:00
q0w
6d0e01e62b socketserver: Set StreamRequestHandler.connection to SSLSocket (#8274) 2022-07-19 09:13:43 -07:00
Alex Waygood
edc0ecd857 Remove Python 3.6 branches from typeshed (#8269) 2022-07-11 10:55:17 +02:00
Alex Waygood
591593c85f Simplify __all__ for modules beginning with 'm' to 't' (#8028) 2022-06-07 20:14:15 +01:00
Alex Waygood
acc0167dc1 Fix several new-in-3.11 stubtest errors (#7973) 2022-06-02 18:07:38 -07:00
Alex Waygood
97a74bc1aa Import from collections.abc wherever possible (#7635) 2022-04-18 12:50:37 +02:00
Alex Waygood
740193a8fc Use TypeAlias where possible for type aliases (#7630) 2022-04-15 18:01:00 -07:00
Alex Waygood
a3bb5af4a0 Add __all__ to most modules beginning with 'q', 'r' and 's' (#7364) 2022-02-22 16:51:54 -08:00
Nikita Sobolev
418574f82c Improve socketserver (#7073)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2022-02-11 17:22:00 -08:00
Shantanu
b88a6f19cd Upgrade black version (#7089) 2022-01-30 16:27:06 -08:00
Alex Waygood
a40d79a4e6 Use lowercase type everywhere (#6853) 2022-01-08 16:09:29 +01:00
Alex Waygood
2268955701 Remove several unused TypeVars (#6829) 2022-01-05 17:58:03 +02:00
Alex Waygood
8d5d2520ac Use PEP 585 syntax wherever possible (#6717) 2021-12-28 11:31:43 +01:00
Alex Waygood
5434243f65 Add socketserver.UDPServer.max_packet_size (#6433)
It looks like an int in the source code: 8d1a580064/Lib/socketserver.py (L524).

Stubtest flagged it as being missing in all supported Python versions, on all platforms: https://github.com/python/typeshed/pull/6403/files
2021-11-28 20:36:23 -08:00
Alex Waygood
5c8e68f0eb Use lowercase set, frozenset and deque where possible (#6346) 2021-11-19 15:05:45 -08:00
Akuli
ee487304d7 Big diff: Use new "|" union syntax (#5872) 2021-08-08 11:05:21 +02:00
Akuli
e3f662b648 switch to lower-case "# undocumented" comments (#5871) 2021-08-07 08:00:41 -07:00
Anton Grübel
96e0660fba Use _typeshed.Self with __enter__ (#5717)
Co-authored-by: Akuli <akuviljanen17@gmail.com>
2021-07-01 12:32:32 +02: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
Michael Lazar
dae5817f16 Fix BaseServer request and client_address types (#4992) 2021-05-28 13:26:39 +02: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