Skip to content

Commit a310b26

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
1 parent 4724060 commit a310b26

22 files changed

+9
-53
lines changed

stdlib/_msi.pyi

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import sys
22

33
if sys.platform == "win32":
4-
54
# Actual typename View, not exposed by the implementation
65
class _View:
76
def Execute(self, params: _Record | None = ...) -> None: ...
@@ -12,6 +11,7 @@ if sys.platform == "win32":
1211
# Don't exist at runtime
1312
__new__: None # type: ignore[assignment]
1413
__init__: None # type: ignore[assignment]
14+
1515
# Actual typename SummaryInformation, not exposed by the implementation
1616
class _SummaryInformation:
1717
def GetProperty(self, field: int) -> int | bytes | None: ...
@@ -21,6 +21,7 @@ if sys.platform == "win32":
2121
# Don't exist at runtime
2222
__new__: None # type: ignore[assignment]
2323
__init__: None # type: ignore[assignment]
24+
2425
# Actual typename Database, not exposed by the implementation
2526
class _Database:
2627
def OpenView(self, sql: str) -> _View: ...
@@ -30,6 +31,7 @@ if sys.platform == "win32":
3031
# Don't exist at runtime
3132
__new__: None # type: ignore[assignment]
3233
__init__: None # type: ignore[assignment]
34+
3335
# Actual typename Record, not exposed by the implementation
3436
class _Record:
3537
def GetFieldCount(self) -> int: ...

stdlib/asyncio/base_subprocess.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ from . import events, futures, protocols, transports
99
_File: TypeAlias = int | IO[Any] | None
1010

1111
class BaseSubprocessTransport(transports.SubprocessTransport):
12-
1312
_closed: bool # undocumented
1413
_protocol: protocols.SubprocessProtocol # undocumented
1514
_loop: events.AbstractEventLoop # undocumented

stdlib/asyncio/proactor_events.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ class _ProactorWritePipeTransport(_ProactorBaseWritePipeTransport): ...
5757
class _ProactorDuplexPipeTransport(_ProactorReadPipeTransport, _ProactorBaseWritePipeTransport, transports.Transport): ...
5858

5959
class _ProactorSocketTransport(_ProactorReadPipeTransport, _ProactorBaseWritePipeTransport, transports.Transport):
60-
6160
_sendfile_compatible: ClassVar[constants._SendfileMode]
6261
def __init__(
6362
self,

stdlib/asyncio/sslproto.pyi

-2
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ else:
3535

3636
if sys.version_info < (3, 11):
3737
class _SSLPipe:
38-
3938
max_size: ClassVar[int]
4039

4140
_context: ssl.SSLContext
@@ -64,7 +63,6 @@ if sys.version_info < (3, 11):
6463
def feed_appdata(self, data: bytes, offset: int = 0) -> tuple[list[bytes], int]: ...
6564

6665
class _SSLProtocolTransport(transports._FlowControlMixin, transports.Transport):
67-
6866
_sendfile_compatible: ClassVar[constants._SendfileMode]
6967

7068
_loop: events.AbstractEventLoop

stdlib/asyncio/unix_events.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ if sys.platform != "win32":
8585
DefaultEventLoopPolicy = _UnixDefaultEventLoopPolicy
8686

8787
if sys.version_info >= (3, 8):
88-
8988
from typing import Protocol
9089

9190
class _Warn(Protocol):

stdlib/asyncore.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ def loop(timeout: float = 30.0, use_poll: bool = False, map: _MapType | None = N
2525
# Not really subclass of socket.socket; it's only delegation.
2626
# It is not covariant to it.
2727
class dispatcher:
28-
2928
debug: bool
3029
connected: bool
3130
accepting: bool

stdlib/bdb.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ class Bdb:
7070
def runcall(self, __func: Callable[_P, _T], *args: _P.args, **kwds: _P.kwargs) -> _T | None: ...
7171

7272
class Breakpoint:
73-
7473
next: int
7574
bplist: dict[tuple[str, int], list[Breakpoint]]
7675
bpbynumber: list[Breakpoint | None]

stdlib/functools.pyi

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ else:
6363
def lru_cache(maxsize: int | None = 128, typed: bool = False) -> Callable[[Callable[..., _T]], _lru_cache_wrapper[_T]]: ...
6464

6565
WRAPPER_ASSIGNMENTS: tuple[
66-
Literal["__module__"], Literal["__name__"], Literal["__qualname__"], Literal["__doc__"], Literal["__annotations__"],
66+
Literal["__module__"], Literal["__name__"], Literal["__qualname__"], Literal["__doc__"], Literal["__annotations__"]
6767
]
6868
WRAPPER_UPDATES: tuple[Literal["__dict__"]]
6969

stdlib/mailbox.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,6 @@ class Mailbox(Generic[_MessageT]):
105105
def __class_getitem__(cls, item: Any) -> GenericAlias: ...
106106

107107
class Maildir(Mailbox[MaildirMessage]):
108-
109108
colon: str
110109
def __init__(
111110
self, dirname: StrPath, factory: Callable[[IO[Any]], MaildirMessage] | None = None, create: bool = True

stdlib/modulefinder.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ class Module: # undocumented
2323
def __init__(self, name: str, file: str | None = None, path: str | None = None) -> None: ...
2424

2525
class ModuleFinder:
26-
2726
modules: dict[str, Module]
2827
path: list[str] # undocumented
2928
badmodules: dict[str, dict[str, int]] # undocumented

stdlib/msilib/__init__.pyi

-8
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ if sys.platform == "win32":
2424
knownbits: Literal[0x3FFF]
2525

2626
class Table:
27-
2827
name: str
2928
fields: list[tuple[int, str, int]]
3029
def __init__(self, name: str) -> None: ...
@@ -50,7 +49,6 @@ if sys.platform == "win32":
5049
def gen_uuid() -> str: ...
5150

5251
class CAB:
53-
5452
name: str
5553
files: list[tuple[str, str]]
5654
filenames: set[str]
@@ -62,7 +60,6 @@ if sys.platform == "win32":
6260
_directories: set[str]
6361

6462
class Directory:
65-
6663
db: _Database
6764
cab: CAB
6865
basedir: str
@@ -98,12 +95,10 @@ if sys.platform == "win32":
9895
def remove_pyc(self) -> None: ...
9996

10097
class Binary:
101-
10298
name: str
10399
def __init__(self, fname: str) -> None: ...
104100

105101
class Feature:
106-
107102
id: str
108103
def __init__(
109104
self,
@@ -120,7 +115,6 @@ if sys.platform == "win32":
120115
def set_current(self) -> None: ...
121116

122117
class Control:
123-
124118
dlg: Dialog
125119
name: str
126120
def __init__(self, dlg: Dialog, name: str) -> None: ...
@@ -129,14 +123,12 @@ if sys.platform == "win32":
129123
def condition(self, action: str, condition: str) -> None: ...
130124

131125
class RadioButtonGroup(Control):
132-
133126
property: str
134127
index: int
135128
def __init__(self, dlg: Dialog, name: str, property: str) -> None: ...
136129
def add(self, name: str, x: int, y: int, w: int, h: int, text: str, value: str | None = None) -> None: ...
137130

138131
class Dialog:
139-
140132
db: _Database
141133
name: str
142134
x: int

stdlib/msilib/sequence.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import sys
22
from typing_extensions import TypeAlias
33

44
if sys.platform == "win32":
5-
65
_SequenceType: TypeAlias = list[tuple[str, str | None, int]]
76

87
AdminExecuteSequence: _SequenceType

stdlib/msilib/text.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import sys
22

33
if sys.platform == "win32":
4-
54
ActionText: list[tuple[str, str, str | None]]
65
UIText: list[tuple[str, str | None]]
76

stdlib/xmlrpc/client.pyi

-13
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ INTERNAL_ERROR: int # undocumented
5555
class Error(Exception): ...
5656

5757
class ProtocolError(Error):
58-
5958
url: str
6059
errcode: int
6160
errmsg: str
@@ -65,7 +64,6 @@ class ProtocolError(Error):
6564
class ResponseError(Error): ...
6665

6766
class Fault(Error):
68-
6967
faultCode: int
7068
faultString: str
7169
def __init__(self, faultCode: int, faultString: str, **extra: Any) -> None: ...
@@ -77,7 +75,6 @@ def _iso8601_format(value: datetime) -> str: ... # undocumented
7775
def _strftime(value: _XMLDate) -> str: ... # undocumented
7876

7977
class DateTime:
80-
8178
value: str # undocumented
8279
def __init__(self, value: int | str | datetime | time.struct_time | tuple[int, ...] = 0) -> None: ...
8380
def __lt__(self, other: _DateTimeComparable) -> bool: ...
@@ -94,7 +91,6 @@ def _datetime(data: Any) -> DateTime: ... # undocumented
9491
def _datetime_type(data: str) -> datetime: ... # undocumented
9592

9693
class Binary:
97-
9894
data: bytes
9995
def __init__(self, data: bytes | bytearray | None = None) -> None: ...
10096
def decode(self, data: ReadableBuffer) -> None: ...
@@ -137,7 +133,6 @@ class Marshaller:
137133
def dump_instance(self, value: object, write: _WriteCallback) -> None: ...
138134

139135
class Unmarshaller:
140-
141136
dispatch: dict[str, Callable[[Unmarshaller, str], None]]
142137

143138
_type: str | None
@@ -174,21 +169,18 @@ class Unmarshaller:
174169
def end_methodName(self, data: str) -> None: ...
175170

176171
class _MultiCallMethod: # undocumented
177-
178172
__call_list: list[tuple[str, tuple[_Marshallable, ...]]]
179173
__name: str
180174
def __init__(self, call_list: list[tuple[str, _Marshallable]], name: str) -> None: ...
181175
def __getattr__(self, name: str) -> _MultiCallMethod: ...
182176
def __call__(self, *args: _Marshallable) -> None: ...
183177

184178
class MultiCallIterator: # undocumented
185-
186179
results: list[list[_Marshallable]]
187180
def __init__(self, results: list[list[_Marshallable]]) -> None: ...
188181
def __getitem__(self, i: int) -> _Marshallable: ...
189182

190183
class MultiCall:
191-
192184
__server: ServerProxy
193185
__call_list: list[tuple[str, tuple[_Marshallable, ...]]]
194186
def __init__(self, server: ServerProxy) -> None: ...
@@ -215,20 +207,17 @@ def gzip_encode(data: ReadableBuffer) -> bytes: ... # undocumented
215207
def gzip_decode(data: ReadableBuffer, max_decode: int = ...) -> bytes: ... # undocumented
216208

217209
class GzipDecodedResponse(gzip.GzipFile): # undocumented
218-
219210
io: BytesIO
220211
def __init__(self, response: SupportsRead[ReadableBuffer]) -> None: ...
221212

222213
class _Method: # undocumented
223-
224214
__send: Callable[[str, tuple[_Marshallable, ...]], _Marshallable]
225215
__name: str
226216
def __init__(self, send: Callable[[str, tuple[_Marshallable, ...]], _Marshallable], name: str) -> None: ...
227217
def __getattr__(self, name: str) -> _Method: ...
228218
def __call__(self, *args: _Marshallable) -> _Marshallable: ...
229219

230220
class Transport:
231-
232221
user_agent: str
233222
accept_gzip_encoding: bool
234223
encode_threshold: int | None
@@ -264,7 +253,6 @@ class Transport:
264253
def parse_response(self, response: http.client.HTTPResponse) -> tuple[_Marshallable, ...]: ...
265254

266255
class SafeTransport(Transport):
267-
268256
if sys.version_info >= (3, 8):
269257
def __init__(
270258
self,
@@ -282,7 +270,6 @@ class SafeTransport(Transport):
282270
def make_connection(self, host: _HostType) -> http.client.HTTPSConnection: ...
283271

284272
class ServerProxy:
285-
286273
__host: str
287274
__handler: str
288275
__transport: Transport

stdlib/xmlrpc/server.pyi

-4
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ def resolve_dotted_attribute(obj: Any, attr: str, allow_dotted_names: bool = Tru
3636
def list_public_methods(obj: Any) -> list[str]: ... # undocumented
3737

3838
class SimpleXMLRPCDispatcher: # undocumented
39-
4039
funcs: dict[str, _DispatchProtocol]
4140
instance: Any | None
4241
allow_none: bool
@@ -70,7 +69,6 @@ class SimpleXMLRPCRequestHandler(http.server.BaseHTTPRequestHandler):
7069
def report_404(self) -> None: ...
7170

7271
class SimpleXMLRPCServer(socketserver.TCPServer, SimpleXMLRPCDispatcher):
73-
7472
_send_traceback_handler: bool
7573
def __init__(
7674
self,
@@ -84,7 +82,6 @@ class SimpleXMLRPCServer(socketserver.TCPServer, SimpleXMLRPCDispatcher):
8482
) -> None: ...
8583

8684
class MultiPathXMLRPCServer(SimpleXMLRPCServer): # undocumented
87-
8885
dispatchers: dict[str, SimpleXMLRPCDispatcher]
8986
def __init__(
9087
self,
@@ -119,7 +116,6 @@ class ServerHTMLDoc(pydoc.HTMLDoc): # undocumented
119116
def docserver(self, server_name: str, package_documentation: str, methods: dict[str, str]) -> str: ...
120117

121118
class XMLRPCDocGenerator: # undocumented
122-
123119
server_name: str
124120
server_documentation: str
125121
server_title: str

stubs/Pillow/PIL/Image.pyi

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ _Size: TypeAlias = tuple[int, int]
2323
_Box: TypeAlias = tuple[int, int, int, int]
2424

2525
_ConversionMatrix: TypeAlias = Union[
26-
tuple[float, float, float, float], tuple[float, float, float, float, float, float, float, float, float, float, float, float],
26+
tuple[float, float, float, float], tuple[float, float, float, float, float, float, float, float, float, float, float, float]
2727
]
2828
# `str` values are only accepted if mode="RGB" for an `Image` object
2929
# `float` values are only accepted for certain modes such as "F"

stubs/PyScreeze/pyscreeze/__init__.pyi

+1
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@ def pixel(x: int, y: int) -> tuple[int, int, int]: ...
178178
def screenshot(imageFilename: StrOrBytesPath | None = None, region: tuple[int, int, int, int] | None = None) -> Image.Image: ...
179179

180180
grab = screenshot
181+
181182
# _locateAll_opencv
182183
@overload
183184
def locateAll(

stubs/colorama/colorama/winterm.pyi

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import sys
22

33
if sys.platform == "win32":
4-
54
from . import win32
65

76
class WinColor:

0 commit comments

Comments
 (0)