Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix various inheritances #3968

Open
hauntsaninja opened this issue May 6, 2020 · 3 comments
Open

Fix various inheritances #3968

hauntsaninja opened this issue May 6, 2020 · 3 comments
Labels
help wanted An actionable problem of low to medium complexity where a PR would be very welcome

Comments

@hauntsaninja
Copy link
Collaborator

hauntsaninja commented May 6, 2020

I had a patch to stubtest that added checking of base classes. Unfortunately, it was too noisy to consider merging, although some fixes did come out of it.
I complicated the patch today, and most of the following look actionable. Figured I'd jot the output down here, so it doesn't get forgotten about, since I'm not sure I want to merge this newly complicated patch (branch at https://github.com/hauntsaninja/mypy/tree/stubtestbaseclass). I'll chip away at these, but if someone reading this is looking to contribute to typeshed, this is a good place to start!

~/dev/mypy stubtestbaseclass λ python3.8 -m mypy.stubtest --custom-typeshed-dir ~/dev/typeshed --check-typeshed
error: asyncio.locks._ContextManagerMixin is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 14
<TypeInfo asyncio.locks._ContextManagerMixin> inherits from asyncio.futures.Future
MRO: asyncio.locks._ContextManagerMixin, asyncio.futures.Future, typing.Awaitable, typing.Iterable, builtins.object
Runtime: at line 49 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/asyncio/locks.py
<class 'asyncio.locks._ContextManagerMixin'> inherits from builtins.object
MRO: asyncio.locks._ContextManagerMixin, builtins.object

error: asyncio.protocols.BufferedProtocol is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 14
<TypeInfo asyncio.protocols.BufferedProtocol> inherits from asyncio.protocols.Protocol
MRO: asyncio.protocols.BufferedProtocol, asyncio.protocols.Protocol, asyncio.protocols.BaseProtocol, builtins.object
Runtime: at line 109 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/asyncio/protocols.py
<class 'asyncio.protocols.BufferedProtocol'> inherits from asyncio.protocols.BaseProtocol
MRO: asyncio.protocols.BufferedProtocol, asyncio.protocols.BaseProtocol, builtins.object

error: concurrent.futures.process.BrokenProcessPool is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 8
<TypeInfo concurrent.futures.process.BrokenProcessPool> inherits from builtins.RuntimeError
MRO: concurrent.futures.process.BrokenProcessPool, builtins.RuntimeError, builtins.Exception, builtins.BaseException, builtins.object
Runtime: at line 490 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/concurrent/futures/process.py
<class 'concurrent.futures.process.BrokenProcessPool'> inherits from concurrent.futures._base.BrokenExecutor
MRO: concurrent.futures.process.BrokenProcessPool, concurrent.futures._base.BrokenExecutor, builtins.RuntimeError, builtins.Exception, builtins.BaseException, builtins.object

error: ctypes.LittleEndianStructure is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 261
<TypeInfo ctypes.LittleEndianStructure> inherits from ctypes.Structure
MRO: ctypes.LittleEndianStructure, ctypes.Structure, ctypes._StructUnionBase, ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Structure'> inherits from _ctypes._CData
MRO: _ctypes.Structure, _ctypes._CData, builtins.object

error: distutils.command.build_py.build_py_2to3 is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 10
<TypeInfo distutils.command.build_py.build_py_2to3> inherits from distutils.command.build_py.build_py
MRO: distutils.command.build_py.build_py_2to3, distutils.command.build_py.build_py, distutils.cmd.Command, builtins.object
Runtime: at line 394 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/distutils/command/build_py.py
<class 'distutils.command.build_py.build_py_2to3'> inherits from distutils.command.build_py.build_py, distutils.util.Mixin2to3
MRO: distutils.command.build_py.build_py_2to3, distutils.command.build_py.build_py, distutils.cmd.Command, distutils.util.Mixin2to3, builtins.object

error: email.feedparser.BytesFeedParser is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 13
<TypeInfo email.feedparser.BytesFeedParser> inherits from builtins.object
MRO: email.feedparser.BytesFeedParser, builtins.object
Runtime: at line 532 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/email/feedparser.py
<class 'email.feedparser.BytesFeedParser'> inherits from email.feedparser.FeedParser
MRO: email.feedparser.BytesFeedParser, email.feedparser.FeedParser, builtins.object

error: email.generator.BytesGenerator is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 16
<TypeInfo email.generator.BytesGenerator> inherits from builtins.object
MRO: email.generator.BytesGenerator, builtins.object
Runtime: at line 392 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/email/generator.py
<class 'email.generator.BytesGenerator'> inherits from email.generator.Generator
MRO: email.generator.BytesGenerator, email.generator.Generator, builtins.object

error: enum.auto is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 57
<TypeInfo enum.auto> inherits from enum.IntFlag
MRO: enum.auto, enum.IntFlag, builtins.int, enum.Flag, enum.Enum, builtins.object
Runtime: at line 44 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/enum.py
<class 'enum.auto'> inherits from builtins.object
MRO: enum.auto, builtins.object

error: io.BufferedRandom is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 132
<TypeInfo io.BufferedRandom> inherits from io.BufferedReader, io.BufferedWriter
MRO: io.BufferedRandom, io.BufferedReader, io.BufferedWriter, io.BufferedIOBase, io.IOBase, builtins.object
Runtime:
<class '_io.BufferedRandom'> inherits from _io._BufferedIOBase
MRO: _io.BufferedRandom, _io._BufferedIOBase, _io._IOBase, builtins.object

error: io.IncrementalNewlineDecoder is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 215
<TypeInfo io.IncrementalNewlineDecoder> inherits from codecs.IncrementalDecoder
MRO: io.IncrementalNewlineDecoder, codecs.IncrementalDecoder, builtins.object
Runtime:
<class '_io.IncrementalNewlineDecoder'> inherits from builtins.object
MRO: _io.IncrementalNewlineDecoder, builtins.object

error: io.StringIO is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 205
<TypeInfo io.StringIO> inherits from io.TextIOWrapper
MRO: io.StringIO, io.TextIOWrapper, typing.TextIO, typing.IO, typing.Iterator, typing.Iterable, builtins.object
Runtime:
<class '_io.StringIO'> inherits from _io._TextIOBase
MRO: _io.StringIO, _io._TextIOBase, _io._IOBase, builtins.object

error: multiprocessing.queues.Queue is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 7
<TypeInfo multiprocessing.queues.Queue> inherits from queue.Queue
MRO: multiprocessing.queues.Queue, queue.Queue, builtins.object
Runtime: at line 34 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/multiprocessing/queues.py
<class 'multiprocessing.queues.Queue'> inherits from builtins.object
MRO: multiprocessing.queues.Queue, builtins.object

error: os._wrap_close is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 603
<TypeInfo os._wrap_close> inherits from io.TextIOWrapper
MRO: os._wrap_close, io.TextIOWrapper, typing.TextIO, typing.IO, typing.Iterator, typing.Iterable, builtins.object
Runtime: at line 996 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/os.py
<class 'os._wrap_close'> inherits from builtins.object
MRO: os._wrap_close, builtins.object

error: selectors.DefaultSelector is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 75
<TypeInfo selectors.DefaultSelector> inherits from selectors.BaseSelector
MRO: selectors.DefaultSelector, selectors.BaseSelector, builtins.object
Runtime: at line 506 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/selectors.py
<class 'selectors.KqueueSelector'> inherits from selectors._BaseSelectorImpl
MRO: selectors.KqueueSelector, selectors._BaseSelectorImpl, selectors.BaseSelector, builtins.object

error: socketserver.UDPServer is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 50
<TypeInfo socketserver.UDPServer> inherits from socketserver.BaseServer
MRO: socketserver.UDPServer, socketserver.BaseServer, builtins.object
Runtime: at line 516 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/socketserver.py
<class 'socketserver.UDPServer'> inherits from socketserver.TCPServer
MRO: socketserver.UDPServer, socketserver.TCPServer, socketserver.BaseServer, builtins.object

error: socketserver.UnixDatagramServer is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 61
<TypeInfo socketserver.UnixDatagramServer> inherits from socketserver.BaseServer
MRO: socketserver.UnixDatagramServer, socketserver.BaseServer, builtins.object
Runtime: at line 689 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/socketserver.py
<class 'socketserver.UnixDatagramServer'> inherits from socketserver.UDPServer
MRO: socketserver.UnixDatagramServer, socketserver.UDPServer, socketserver.TCPServer, socketserver.BaseServer, builtins.object

error: socketserver.UnixStreamServer is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 56
<TypeInfo socketserver.UnixStreamServer> inherits from socketserver.BaseServer
MRO: socketserver.UnixStreamServer, socketserver.BaseServer, builtins.object
Runtime: at line 686 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/socketserver.py
<class 'socketserver.UnixStreamServer'> inherits from socketserver.TCPServer
MRO: socketserver.UnixStreamServer, socketserver.TCPServer, socketserver.BaseServer, builtins.object

error: threading.BoundedSemaphore is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 148
<TypeInfo threading.BoundedSemaphore> inherits from builtins.object
MRO: threading.BoundedSemaphore, builtins.object
Runtime: at line 456 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/threading.py
<class 'threading.BoundedSemaphore'> inherits from threading.Semaphore
MRO: threading.BoundedSemaphore, threading.Semaphore, builtins.object

error: tracemalloc.DomainFilter is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 17
<TypeInfo tracemalloc.DomainFilter> inherits from builtins.object
MRO: tracemalloc.DomainFilter, builtins.object
Runtime: at line 375 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/tracemalloc.py
<class 'tracemalloc.DomainFilter'> inherits from tracemalloc.BaseFilter
MRO: tracemalloc.DomainFilter, tracemalloc.BaseFilter, builtins.object

error: tracemalloc.Filter is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 22
<TypeInfo tracemalloc.Filter> inherits from builtins.object
MRO: tracemalloc.Filter, builtins.object
Runtime: at line 327 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/tracemalloc.py
<class 'tracemalloc.Filter'> inherits from tracemalloc.BaseFilter
MRO: tracemalloc.Filter, tracemalloc.BaseFilter, builtins.object

error: typing.NamedTuple is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 627
<TypeInfo typing.NamedTuple> inherits from builtins.tuple
MRO: typing.NamedTuple, builtins.tuple, typing.Sequence, typing.Collection, typing.Iterable, typing.Container, typing.Reversible, builtins.object
Runtime: at line 1641 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/typing.py
<class 'typing.NamedTuple'> inherits from builtins.object
MRO: typing.NamedTuple, builtins.object

error: unittest.TextTestRunner is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 24
<TypeInfo unittest.runner.TextTestRunner> inherits from unittest.runner.TestRunner
MRO: unittest.runner.TextTestRunner, unittest.runner.TestRunner, builtins.object
Runtime: at line 120 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/unittest/runner.py
<class 'unittest.runner.TextTestRunner'> inherits from builtins.object
MRO: unittest.runner.TextTestRunner, builtins.object

error: unittest.mock.Mock is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 126
<TypeInfo unittest.mock.Mock> inherits from unittest.mock.NonCallableMock, unittest.mock.CallableMixin
MRO: unittest.mock.Mock, unittest.mock.NonCallableMock, unittest.mock.CallableMixin, unittest.mock.Base, builtins.object
Runtime: at line 1161 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/unittest/mock.py
<class 'unittest.mock.Mock'> inherits from unittest.mock.CallableMixin, unittest.mock.NonCallableMock
MRO: unittest.mock.Mock, unittest.mock.CallableMixin, unittest.mock.NonCallableMock, unittest.mock.Base, builtins.object

error: unittest.runner.TextTestRunner is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 24
<TypeInfo unittest.runner.TextTestRunner> inherits from unittest.runner.TestRunner
MRO: unittest.runner.TextTestRunner, unittest.runner.TestRunner, builtins.object
Runtime: at line 120 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/unittest/runner.py
<class 'unittest.runner.TextTestRunner'> inherits from builtins.object
MRO: unittest.runner.TextTestRunner, builtins.object

error: weakref.KeyedRef is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 66
<TypeInfo weakref.KeyedRef> inherits from _weakref.ReferenceType
MRO: weakref.KeyedRef, _weakref.ReferenceType, builtins.object
Runtime: at line 311 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/weakref.py
<class 'weakref.KeyedRef'> inherits from builtins.weakref
MRO: weakref.KeyedRef, builtins.weakref, builtins.object

error: weakref.WeakMethod is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 29
<TypeInfo weakref.WeakMethod> inherits from _weakref.ReferenceType
MRO: weakref.WeakMethod, _weakref.ReferenceType, builtins.object
Runtime: at line 36 in file /Users/shantanu/.pyenv/versions/3.8.2/lib/python3.8/weakref.py
<class 'weakref.WeakMethod'> inherits from builtins.weakref
MRO: weakref.WeakMethod, builtins.weakref, builtins.object
@srittau
Copy link
Collaborator

srittau commented May 6, 2020

Would it make sense to add an option to disable these checks, so we could disable them in CI for now?

@AlexWaygood
Copy link
Member

Here's the results I get from running @hauntsaninja's branch on the stdlib in 2022. Several have been fixed, but there's also a few new ones:

error: ctypes.LittleEndianStructure is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 257
<TypeInfo ctypes.LittleEndianStructure> inherits from ctypes.Structure
MRO: ctypes.LittleEndianStructure, ctypes.Structure, ctypes._StructUnionBase, ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Structure'> inherits from _ctypes._CData
MRO: _ctypes.Structure, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPBOOL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPBYTE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_byte'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_byte, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPCOLORREF is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPDWORD is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPFILETIME is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_FILETIME'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_FILETIME, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPHANDLE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_void_p'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_void_p, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPHKL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_void_p'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_void_p, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPLONG is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPMSG is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_MSG'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_MSG, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPPOINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_POINT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_POINT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPRECT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_RECT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_RECT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPRECTL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_RECT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_RECT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPSC_HANDLE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_void_p'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_void_p, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPSIZE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_SIZE'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_SIZE, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPSIZEL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_SIZE'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_SIZE, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPUINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPWIN32_FIND_DATAA is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_WIN32_FIND_DATAA'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_WIN32_FIND_DATAA, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPWIN32_FIND_DATAW is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_WIN32_FIND_DATAW'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_WIN32_FIND_DATAW, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.LPWORD is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ushort'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ushort, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PBOOL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PBOOLEAN is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_byte'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_byte, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PBYTE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_byte'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_byte, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PCHAR is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\__init__.py
<class 'ctypes.LP_c_char'> inherits from _ctypes._Pointer
MRO: ctypes.LP_c_char, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PDWORD is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PFILETIME is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_FILETIME'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_FILETIME, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PFLOAT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_float'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_float, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PHANDLE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_void_p'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_void_p, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PHKEY is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_void_p'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_void_p, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PLARGE_INTEGER is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_longlong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_longlong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PLCID is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PLONG is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_long'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_long, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PMSG is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_MSG'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_MSG, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PPOINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_POINT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_POINT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PPOINTL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_POINT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_POINT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PRECT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_RECT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_RECT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PRECTL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_RECT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_RECT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PSHORT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_short'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_short, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PSIZE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_SIZE'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_SIZE, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PSIZEL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_SIZE'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_SIZE, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PSMALL_RECT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP__SMALL_RECT'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP__SMALL_RECT, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PUINT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PULARGE_INTEGER is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulonglong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulonglong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PULONG is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ulong'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ulong, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PUSHORT is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ushort'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ushort, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PWCHAR is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\__init__.py
<class 'ctypes.LP_c_wchar'> inherits from _ctypes._Pointer
MRO: ctypes.LP_c_wchar, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PWIN32_FIND_DATAA is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_WIN32_FIND_DATAA'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_WIN32_FIND_DATAA, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PWIN32_FIND_DATAW is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_WIN32_FIND_DATAW'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_WIN32_FIND_DATAW, _ctypes._Pointer, _ctypes._CData, builtins.object

error: ctypes.wintypes.PWORD is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 164
<TypeInfo ctypes.pointer> inherits from ctypes._PointerLike, ctypes._CData
MRO: ctypes.pointer, ctypes._PointerLike, ctypes._CanCastTo, ctypes._CData, builtins.object
Runtime: in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\ctypes\wintypes.py
<class 'ctypes.wintypes.LP_c_ushort'> inherits from _ctypes._Pointer
MRO: ctypes.wintypes.LP_c_ushort, _ctypes._Pointer, _ctypes._CData, builtins.object

error: dataclasses._MISSING_TYPE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 38
<TypeInfo dataclasses._MISSING_TYPE> inherits from enum.Enum
MRO: dataclasses._MISSING_TYPE, enum.Enum, builtins.object
Runtime: at line 184 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\dataclasses.py
<class 'dataclasses._MISSING_TYPE'> inherits from builtins.object
MRO: dataclasses._MISSING_TYPE, builtins.object

error: email.feedparser.BytesFeedParser is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 18
<TypeInfo email.feedparser.BytesFeedParser> inherits from builtins.object
MRO: email.feedparser.BytesFeedParser, builtins.object
Runtime: at line 532 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\email\feedparser.py
<class 'email.feedparser.BytesFeedParser'> inherits from email.feedparser.FeedParser
MRO: email.feedparser.BytesFeedParser, email.feedparser.FeedParser, builtins.object

error: email.generator.BytesGenerator is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 20
<TypeInfo email.generator.BytesGenerator> inherits from builtins.object
MRO: email.generator.BytesGenerator, builtins.object
Runtime: at line 396 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\email\generator.py
<class 'email.generator.BytesGenerator'> inherits from email.generator.Generator
MRO: email.generator.BytesGenerator, email.generator.Generator, builtins.object

error: email.parser.BytesFeedParser is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 18
<TypeInfo email.feedparser.BytesFeedParser> inherits from builtins.object
MRO: email.feedparser.BytesFeedParser, builtins.object
Runtime: at line 532 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\email\feedparser.py
<class 'email.feedparser.BytesFeedParser'> inherits from email.feedparser.FeedParser
MRO: email.feedparser.BytesFeedParser, email.feedparser.FeedParser, builtins.object

error: enum.auto is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 200
<TypeInfo enum.auto> inherits from enum.IntFlag
MRO: enum.auto, enum.IntFlag, builtins.int, enum.Flag, enum.Enum, builtins.object
Runtime: at line 68 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\enum.py
<class 'enum.auto'> inherits from builtins.object
MRO: enum.auto, builtins.object

error: importlib.metadata.EntryPoints is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 65
<TypeInfo importlib.metadata.EntryPoints> inherits from builtins.list
MRO: importlib.metadata.EntryPoints, builtins.list, typing.MutableSequence, typing.Sequence, typing.Collection, typing.Reversible, typing.Iterable, typing.Container, builtins.object
Runtime: at line 330 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\importlib\metadata\__init__.py
<class 'importlib.metadata.EntryPoints'> inherits from importlib.metadata.DeprecatedList
MRO: importlib.metadata.EntryPoints, importlib.metadata.DeprecatedList, builtins.list, builtins.object

error: importlib.metadata.SelectableGroups is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 83
<TypeInfo importlib.metadata.SelectableGroups> inherits from builtins.dict
MRO: importlib.metadata.SelectableGroups, builtins.dict, typing.MutableMapping, typing.Mapping, typing.Collection, typing.Iterable, typing.Container, builtins.object
Runtime: at line 450 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\importlib\metadata\__init__.py
<class 'importlib.metadata.SelectableGroups'> inherits from importlib.metadata.Deprecated, builtins.dict
MRO: importlib.metadata.SelectableGroups, importlib.metadata.Deprecated, builtins.dict, builtins.object

error: io.BufferedRandom is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 132
<TypeInfo io.BufferedRandom> inherits from io.BufferedReader, io.BufferedWriter
MRO: io.BufferedRandom, io.BufferedReader, io.BufferedWriter, io.BufferedIOBase, io.IOBase, typing.BinaryIO, typing.IO, typing.Iterator, typing.Iterable, builtins.object
Runtime:
<class '_io.BufferedRandom'> inherits from _io._BufferedIOBase
MRO: _io.BufferedRandom, _io._BufferedIOBase, _io._IOBase, builtins.object

error: io.IncrementalNewlineDecoder is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 204
<TypeInfo io.IncrementalNewlineDecoder> inherits from codecs.IncrementalDecoder
MRO: io.IncrementalNewlineDecoder, codecs.IncrementalDecoder, builtins.object
Runtime:
<class '_io.IncrementalNewlineDecoder'> inherits from builtins.object
MRO: _io.IncrementalNewlineDecoder, builtins.object

error: io.StringIO is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 196
<TypeInfo io.StringIO> inherits from io.TextIOWrapper
MRO: io.StringIO, io.TextIOWrapper, io.TextIOBase, io.IOBase, typing.TextIO, typing.IO, typing.Iterator, typing.Iterable, builtins.object
Runtime:
<class '_io.StringIO'> inherits from _io._TextIOBase
MRO: _io.StringIO, _io._TextIOBase, _io._IOBase, builtins.object

error: multiprocessing.queues.Queue is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 12
<TypeInfo multiprocessing.queues.Queue> inherits from queue.Queue
MRO: multiprocessing.queues.Queue, queue.Queue, builtins.object
Runtime: at line 35 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\multiprocessing\queues.py
<class 'multiprocessing.queues.Queue'> inherits from builtins.object
MRO: multiprocessing.queues.Queue, builtins.object

error: os._wrap_close is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 865
<TypeInfo os._wrap_close> inherits from io.TextIOWrapper
MRO: os._wrap_close, io.TextIOWrapper, io.TextIOBase, io.IOBase, typing.TextIO, typing.IO, typing.Iterator, typing.Iterable, builtins.object
Runtime: at line 998 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\os.py
<class 'os._wrap_close'> inherits from builtins.object
MRO: os._wrap_close, builtins.object

error: pathlib.PurePath is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 23
<TypeInfo pathlib.PurePath> inherits from os.PathLike
MRO: pathlib.PurePath, os.PathLike, builtins.object
Runtime: at line 538 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\pathlib.py
<class 'pathlib.PurePath'> inherits from builtins.object
MRO: pathlib.PurePath, builtins.object

error: selectors.DefaultSelector is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 69
<TypeInfo selectors.DefaultSelector> inherits from selectors.BaseSelector
MRO: selectors.DefaultSelector, selectors.BaseSelector, builtins.object
Runtime: at line 291 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\selectors.py
<class 'selectors.SelectSelector'> inherits from selectors._BaseSelectorImpl
MRO: selectors.SelectSelector, selectors._BaseSelectorImpl, selectors.BaseSelector, builtins.object

error: socketserver.UDPServer is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 83
<TypeInfo socketserver.UDPServer> inherits from socketserver.BaseServer
MRO: socketserver.UDPServer, socketserver.BaseServer, builtins.object
Runtime: at line 516 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\socketserver.py
<class 'socketserver.UDPServer'> inherits from socketserver.TCPServer
MRO: socketserver.UDPServer, socketserver.TCPServer, socketserver.BaseServer, builtins.object

error: turtle.ScrolledCanvas is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 159
<TypeInfo turtle.ScrolledCanvas> inherits from tkinter.Canvas, tkinter.Frame
MRO: turtle.ScrolledCanvas, tkinter.Canvas, tkinter.Frame, tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.XView, tkinter.YView, builtins.object
Runtime: at line 330 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\turtle.py
<class 'turtle.ScrolledCanvas'> inherits from tkinter.Frame
MRO: turtle.ScrolledCanvas, tkinter.Frame, tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.tix.Form, builtins.object

error: unittest.mock.MagicMixin is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 361
<TypeInfo unittest.mock.MagicMixin> inherits from builtins.object
MRO: unittest.mock.MagicMixin, builtins.object
Runtime: at line 2080 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\unittest\mock.py
<class 'unittest.mock.MagicMixin'> inherits from unittest.mock.Base
MRO: unittest.mock.MagicMixin, unittest.mock.Base, builtins.object

error: unittest.mock.MagicProxy is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 391
<TypeInfo unittest.mock.MagicProxy> inherits from builtins.object
MRO: unittest.mock.MagicProxy, builtins.object
Runtime: at line 2151 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\unittest\mock.py
<class 'unittest.mock.MagicProxy'> inherits from unittest.mock.Base
MRO: unittest.mock.MagicProxy, unittest.mock.Base, builtins.object

error: weakref.KeyedRef is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 88
<TypeInfo weakref.KeyedRef> inherits from _weakref.ReferenceType
MRO: weakref.KeyedRef, _weakref.ReferenceType, builtins.object
Runtime: at line 336 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\weakref.py
<class 'weakref.KeyedRef'> inherits from builtins.weakref
MRO: weakref.KeyedRef, builtins.weakref, builtins.object

error: weakref.WeakMethod is inconsistent, base classes and MRO differ. INHERITANCE
Stub: at line 44
<TypeInfo weakref.WeakMethod> inherits from _weakref.ReferenceType
MRO: weakref.WeakMethod, _weakref.ReferenceType, builtins.object
Runtime: at line 39 in file C:\Users\alexw\AppData\Local\Programs\Python\Python310\lib\weakref.py
<class 'weakref.WeakMethod'> inherits from builtins.weakref
MRO: weakref.WeakMethod, builtins.weakref, builtins.object

@AlexWaygood AlexWaygood added the help wanted An actionable problem of low to medium complexity where a PR would be very welcome label Aug 20, 2022
tungol added a commit to tungol/typeshed that referenced this issue Dec 4, 2023
It matches the protocol, but it's not an explicit subclass. As far
as I can see, it seems okay to just remove that.

related to python#3968
tungol added a commit to tungol/typeshed that referenced this issue Dec 4, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 4, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 6, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 6, 2023
hauntsaninja pushed a commit that referenced this issue Dec 6, 2023
related to #3968

Co-authored-by: Stephen Morton <git@tungol.org>
tungol added a commit to tungol/typeshed that referenced this issue Dec 7, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 7, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 7, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 7, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 7, 2023
JelleZijlstra pushed a commit that referenced this issue Dec 7, 2023
related to #3968

Co-authored-by: Stephen Morton <git@tungol.org>
tungol added a commit to tungol/typeshed that referenced this issue Dec 9, 2023
tungol added a commit to tungol/typeshed that referenced this issue Dec 9, 2023
@tungol tungol mentioned this issue Oct 5, 2024
tungol added a commit to tungol/typeshed that referenced this issue Oct 5, 2024
They call themselves "decimal.*" at runtime, so move them into
decimal.pyi so typshed's name matches.

related to python#3968
JelleZijlstra pushed a commit that referenced this issue Oct 6, 2024
They call themselves "decimal.*" at runtime, so move them into
decimal.pyi so typshed's name matches.

related to #3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 6, 2024
Improves the MRO of ExitStack and AsyncExitStack

related to python#3968
JelleZijlstra pushed a commit that referenced this issue Oct 7, 2024
Improves the MRO of ExitStack and AsyncExitStack

related to #3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 8, 2024
This version keeps it simple and clean: No changes to class bodies.
The only changes here are moving between files and updating the
naming and inheritance.

Related to python#3968 and split from python#12740.
JelleZijlstra pushed a commit that referenced this issue Oct 9, 2024

This version keeps it simple and clean: No changes to class bodies.
The only changes here are moving between files and updating the
naming and inheritance.

Related to #3968 and split from #12740.
tungol added a commit to tungol/typeshed that referenced this issue Oct 10, 2024
improves naming and inheritance for asyncio.Future and asyncio.Task

related to python#3968
@tungol tungol mentioned this issue Oct 10, 2024
JelleZijlstra pushed a commit that referenced this issue Oct 10, 2024
improves naming and inheritance for asyncio.Future and asyncio.Task

related to #3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 10, 2024
Methods are passed through at runtime via __getattr__

related to python#3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 10, 2024
Methods are passed through at runtime via __getattr__

related to python#3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 10, 2024
This MR breaks out _frozen_importlib_external (which is the same
thing as importlib._bootstrap_external) and _frozen_importlib
(which is the same thing as importlib._bootstrap).

related to python#3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 10, 2024
This MR breaks out _frozen_importlib_external (which is the same
thing as importlib._bootstrap_external) and _frozen_importlib
(which is the same thing as importlib._bootstrap).

related to python#3968
tungol added a commit to tungol/typeshed that referenced this issue Oct 22, 2024
@tungol
Copy link
Contributor

tungol commented Oct 22, 2024

This is getting very close to done now. With the original version of the check run on 3.12 on my macbook, here's what's still left, most of which is unfixable:

error: ctypes.LittleEndianStructure is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/ctypes/__init__.pyi:7
<TypeInfo ctypes._endian.LittleEndianStructure> inherits from _ctypes.Structure
MRO: ctypes._endian.LittleEndianStructure, _ctypes.Structure, _ctypes._StructUnionBase, _ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Structure'> inherits from _ctypes._CData
MRO: _ctypes.Structure, _ctypes._CData, builtins.object

error: ctypes.LittleEndianUnion is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/ctypes/__init__.pyi:12
<TypeInfo ctypes._endian.LittleEndianUnion> inherits from _ctypes.Union
MRO: ctypes._endian.LittleEndianUnion, _ctypes.Union, _ctypes._StructUnionBase, _ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Union'> inherits from _ctypes._CData
MRO: _ctypes.Union, _ctypes._CData, builtins.object

error: ctypes._endian.LittleEndianStructure is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/ctypes/_endian.pyi:7
<TypeInfo ctypes._endian.LittleEndianStructure> inherits from _ctypes.Structure
MRO: ctypes._endian.LittleEndianStructure, _ctypes.Structure, _ctypes._StructUnionBase, _ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Structure'> inherits from _ctypes._CData
MRO: _ctypes.Structure, _ctypes._CData, builtins.object

error: ctypes._endian.LittleEndianUnion is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/ctypes/_endian.pyi:12
<TypeInfo ctypes._endian.LittleEndianUnion> inherits from _ctypes.Union
MRO: ctypes._endian.LittleEndianUnion, _ctypes.Union, _ctypes._StructUnionBase, _ctypes._CData, builtins.object
Runtime:
<class '_ctypes.Union'> inherits from _ctypes._CData
MRO: _ctypes.Union, _ctypes._CData, builtins.object

These are dynamic at runtime, depending on endianness. No way to accurately represent that in typeshed.
LittleEndianUnion is 3.11 and higher only, as it doesn't exist before then.

error: enum.property is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/enum.pyi:181
<TypeInfo enum.property> inherits from builtins.property
MRO: enum.property, builtins.property, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/enum.py:184
<class 'enum.property'> inherits from types.DynamicClassAttribute
MRO: enum.property, types.DynamicClassAttribute, builtins.object

This one is piggy-backing on special casing of builtins.property, and I believe requires additional
special casing added to mypy if it were to be fixed. I gave it a shot in #12762
just to see what it looked like. This only shows up on 3.11 and higher.

error: pathlib.PurePath is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/pathlib.pyi:29
<TypeInfo pathlib.PurePath> inherits from os.PathLike
MRO: pathlib.PurePath, os.PathLike, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/pathlib.py:292
<class 'pathlib.PurePath'> inherits from builtins.object
MRO: pathlib.PurePath, builtins.object

This one shows up in the check, but it's just invalid. pathlib.PurePath gets registered to the
os.PathLike ABC at runtime.

error: tkinter.Widget is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/tkinter/__init__.pyi:923
<TypeInfo tkinter.Widget> inherits from tkinter.BaseWidget, tkinter.Pack, tkinter.Place, tkinter.Grid
MRO: tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/tkinter/__init__.py:2661
<class 'tkinter.Widget'> inherits from tkinter.BaseWidget, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.tix.Form
MRO: tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.tix.Form, builtins.object

On this one, tkinter.tix.Form is added directly to tkinter.Widget.__bases__ at runtime. There's
nothing typeshed can do about it, although I gave it a shot in #12751 .
The good news is that tkinter.tix was removed in 3.13, so this is only a 3.12 and lower issue and will eventually
disappear.

error: dataclasses._MISSING_TYPE is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/dataclasses.pyi:41
<TypeInfo dataclasses._MISSING_TYPE> inherits from enum.Enum
MRO: dataclasses._MISSING_TYPE, enum.Enum, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/dataclasses.py:184
<class 'dataclasses._MISSING_TYPE'> inherits from builtins.object
MRO: dataclasses._MISSING_TYPE, builtins.object

This one is waiting for PEP 661. We'll see what's possible if/when that becomes available.

error: turtle.ScrolledCanvas is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/turtle.pyi:164
<TypeInfo turtle.ScrolledCanvas> inherits from tkinter.Canvas, tkinter.Frame
MRO: turtle.ScrolledCanvas, tkinter.Canvas, tkinter.Frame, tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.XView, tkinter.YView, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/turtle.py:325
<class 'turtle.ScrolledCanvas'> inherits from tkinter.Frame
MRO: turtle.ScrolledCanvas, tkinter.Frame, tkinter.Widget, tkinter.BaseWidget, tkinter.Misc, tkinter.Pack, tkinter.Place, tkinter.Grid, tkinter.tix.Form, builtins.object

At runtime, turtle.ScrolledCanvas is not a subclass of tkinter.Canvas. A helper function runs which
copies all methods from tkinter.Canvas to turtle.ScrolledCanvas dynamically.
This one could be fixed, but the number of methods on tkinter.Canvas is very large and I'm not
sure that even I think that it's worth fixing.

error: importlib.machinery.ExtensionFileLoader is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/importlib/machinery.pyi:151
<TypeInfo importlib.machinery.ExtensionFileLoader> inherits from importlib.abc.ExecutionLoader
MRO: importlib.machinery.ExtensionFileLoader, importlib.abc.ExecutionLoader, importlib.abc.InspectLoader, importlib._abc.Loader, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/importlib/_bootstrap_external.py:1267
<class '_frozen_importlib_external.ExtensionFileLoader'> inherits from _frozen_importlib_external.FileLoader, _frozen_importlib_external._LoaderBasics
MRO: _frozen_importlib_external.ExtensionFileLoader, _frozen_importlib_external.FileLoader, _frozen_importlib_external._LoaderBasics, builtins.object

error: importlib.machinery.SourceFileLoader is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/importlib/machinery.pyi:146
<TypeInfo importlib.machinery.SourceFileLoader> inherits from importlib.abc.FileLoader, importlib.abc.SourceLoader
MRO: importlib.machinery.SourceFileLoader, importlib.abc.FileLoader, importlib.abc.SourceLoader, importlib.abc.ResourceLoader, importlib.abc.ExecutionLoader, importlib.abc.InspectLoader, importlib._abc.Loader, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/importlib/_bootstrap_external.py:1197
<class '_frozen_importlib_external.SourceFileLoader'> inherits from _frozen_importlib_external.FileLoader, _frozen_importlib_external.SourceLoader
MRO: _frozen_importlib_external.SourceFileLoader, _frozen_importlib_external.FileLoader, _frozen_importlib_external.SourceLoader, _frozen_importlib_external._LoaderBasics, builtins.object

error: importlib.machinery.SourcelessFileLoader is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/importlib/machinery.pyi:149
<TypeInfo importlib.machinery.SourcelessFileLoader> inherits from importlib.abc.FileLoader, importlib.abc.SourceLoader
MRO: importlib.machinery.SourcelessFileLoader, importlib.abc.FileLoader, importlib.abc.SourceLoader, importlib.abc.ResourceLoader, importlib.abc.ExecutionLoader, importlib.abc.InspectLoader, importlib._abc.Loader, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/importlib/_bootstrap_external.py:1242
<class '_frozen_importlib_external.SourcelessFileLoader'> inherits from _frozen_importlib_external.FileLoader, _frozen_importlib_external._LoaderBasics
MRO: _frozen_importlib_external.SourcelessFileLoader, _frozen_importlib_external.FileLoader, _frozen_importlib_external._LoaderBasics, builtins.object

These three are fixable, and #12775 fixes them.

On 3.9 and lower, there's a few more:

error: typing_extensions.ParamSpec is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:483
<TypeInfo typing_extensions.ParamSpec> inherits from builtins.object
MRO: typing_extensions.ParamSpec, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:1611
<class 'typing_extensions.ParamSpec'> inherits from builtins.list, typing_extensions._DefaultMixin
MRO: typing_extensions.ParamSpec, builtins.list, typing_extensions._DefaultMixin, builtins.object

I suspect this could be fixed, but I haven't paid it very much attention since it's both 3.9- only and
in typing_extensions.

error: typing_extensions.SupportsAbs is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:407
<TypeInfo typing.SupportsAbs> inherits from builtins.object
MRO: typing.SupportsAbs, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:832
<class 'typing_extensions.SupportsAbs'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsAbs, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsBytes is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:397
<TypeInfo typing.SupportsBytes> inherits from builtins.object
MRO: typing.SupportsBytes, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:815
<class 'typing_extensions.SupportsBytes'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsBytes, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsComplex is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:392
<TypeInfo typing.SupportsComplex> inherits from builtins.object
MRO: typing.SupportsComplex, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:806
<class 'typing_extensions.SupportsComplex'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsComplex, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsFloat is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:387
<TypeInfo typing.SupportsFloat> inherits from builtins.object
MRO: typing.SupportsFloat, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:797
<class 'typing_extensions.SupportsFloat'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsFloat, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsIndex is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:286
<TypeInfo typing_extensions.SupportsIndex> inherits from builtins.object
MRO: typing_extensions.SupportsIndex, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:824
<class 'typing_extensions.SupportsIndex'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsIndex, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsInt is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:382
<TypeInfo typing.SupportsInt> inherits from builtins.object
MRO: typing.SupportsInt, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:788
<class 'typing_extensions.SupportsInt'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsInt, typing_extensions.Protocol, typing.Generic, builtins.object

error: typing_extensions.SupportsRound is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing_extensions.pyi:412
<TypeInfo typing.SupportsRound> inherits from builtins.object
MRO: typing.SupportsRound, builtins.object
Runtime: in file /Users/stephen/Developer/clones/mypy/.venv39/lib/python3.9/site-packages/typing_extensions.py:843
<class 'typing_extensions.SupportsRound'> inherits from typing_extensions.Protocol
MRO: typing_extensions.SupportsRound, typing_extensions.Protocol, typing.Generic, builtins.object

These showed up when I ran the check on 3.9 just now, but I don't remember them being there before.
Looks like they're 3.11 and lower. These are more an artifact of stubcheck then anything real.

error: weakref.KeyedRef is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/weakref.pyi:127
<TypeInfo weakref.KeyedRef> inherits from weakref.ReferenceType
MRO: weakref.KeyedRef, weakref.ReferenceType, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/weakref.py:336
<class 'weakref.KeyedRef'> inherits from builtins.weakref
MRO: weakref.KeyedRef, builtins.weakref, builtins.object

error: weakref.WeakMethod is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/weakref.pyi:69
<TypeInfo weakref.WeakMethod> inherits from weakref.ReferenceType
MRO: weakref.WeakMethod, weakref.ReferenceType, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/weakref.py:39
<class 'weakref.WeakMethod'> inherits from builtins.weakref
MRO: weakref.WeakMethod, builtins.weakref, builtins.object

Not fixable; These are artifacts of the fact that classes in _weakref/weakref gave themselves
names within C that didn't match their names within python before 3.10 fixed it.

error: nntplib.NNTP_SSL is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/nntplib.pyi:112
<TypeInfo nntplib.NNTP_SSL> inherits from nntplib.NNTP
MRO: nntplib.NNTP_SSL, nntplib.NNTP, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/nntplib.py:1068
<class 'nntplib.NNTP_SSL'> inherits from nntplib._NNTPBase
MRO: nntplib.NNTP_SSL, nntplib._NNTPBase, builtins.object

error: typing.NamedTuple is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/typing.pyi:915
<TypeInfo typing.NamedTuple> inherits from builtins.tuple
MRO: typing.NamedTuple, builtins.tuple, typing.Sequence, typing.Reversible, typing.Collection, typing.Iterable, typing.Container, builtins.object
Runtime: in file /Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/typing.py:1644
<class 'typing.NamedTuple'> inherits from builtins.object
MRO: typing.NamedTuple, builtins.object

Finally this pair are 3.8 and lower only, which means they're going away soon I believe?
nntplib.NNTP_SSL could be fixed at the cost of duplication (nntplib._NNTPBase was renamed).
NamedTuple is always messy. Neither is worth dealing with.

I actually haven't run it on 3.13 yet, so let's do that now. 3.13 adds:

error: _interpreters.NotShareableError is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/_interpreters.pyi:10
<TypeInfo _interpreters.NotShareableError> inherits from builtins.Exception
MRO: _interpreters.NotShareableError, builtins.Exception, builtins.BaseException, builtins.object
Runtime:
<class 'interpreters.NotShareableError'> inherits from builtins.ValueError
MRO: interpreters.NotShareableError, builtins.ValueError, builtins.Exception, builtins.BaseException, builtins.object

error: multiprocessing.managers.DictProxy is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/multiprocessing/managers.pyi:63
<TypeInfo multiprocessing.managers.DictProxy> inherits from multiprocessing.managers.BaseProxy, typing.MutableMapping
MRO: multiprocessing.managers.DictProxy, multiprocessing.managers.BaseProxy, typing.MutableMapping, typing.Mapping, typing.Collection, typing.Iterable, typing.Container, builtins.object
Runtime: in file /opt/homebrew/Cellar/python@3.13/3.13.0_1/Frameworks/Python.framework/Versions/3.13/lib/python3.13/multiprocessing/managers.py:1179
<class 'multiprocessing.managers.DictProxy'> inherits from multiprocessing.managers.DictProxy
MRO: multiprocessing.managers.DictProxy, multiprocessing.managers.DictProxy, multiprocessing.managers.BaseProxy, builtins.object

error: pathlib.Path is inconsistent, base classes and MRO differ. INHERITANCE
Stub: in file ../typeshed/stdlib/pathlib.pyi:103
<TypeInfo pathlib.Path> inherits from pathlib.PurePath
MRO: pathlib.Path, pathlib.PurePath, os.PathLike, builtins.object
Runtime: in file /opt/homebrew/Cellar/python@3.13/3.13.0_1/Frameworks/Python.framework/Versions/3.13/lib/python3.13/pathlib/_local.py:482
<class 'pathlib._local.Path'> inherits from pathlib._abc.PathBase, pathlib._local.PurePath
MRO: pathlib._local.Path, pathlib._abc.PathBase, pathlib._local.PurePath, pathlib._abc.PurePathBase, builtins.object

_interpreters.NotShareableError looks extremely straightforward.
multiprocessing.managers.DictProxy was already on my list of things to look into, and is probably
fixable but I don't know yet.

pathlib.Path looks basically fixable, but needs investigation to determine how much duplicated code
would be needed to fix it.

And that's everything! I've been working with various stricter versions of the inheritance check
for a while now. I'll probably propose my own version of it for inclusion in stubcheck once I get
things a little more cleaned up, and that can probably mark the end of this issue. Almost there!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted An actionable problem of low to medium complexity where a PR would be very welcome
Projects
None yet
Development

No branches or pull requests

4 participants