Hi. With the latest version of mypy and mypy-zope we're getting mypy errors that I think are cache related. The error goes away after rm -rf .mypy_cache
Here's the smallest repro I could make:
src/zg/foo.py:
from zg.bar import ZGScriptProtocol
print(ZGScriptProtocol.transport)
src/zg/bar.py:
from twisted.internet.protocol import ProcessProtocol
class ZGScriptProtocol(ProcessProtocol):
pass
I am able to reliably hit the problem by running the following commands:
$ rm -rf .mypy_cache
$ mypy src/zg/foo.py
Success: no issues found in 1 source file
$ mypy src/zg/foo.py src/zg/bar.py
src/zg/bar.py:3: error: Cannot determine consistent method resolution order (MRO) for "ZGScriptProtocol"
src/zg/foo.py:3: error: "Type[ZGScriptProtocol]" has no attribute "transport"
Hi. With the latest version of mypy and mypy-zope we're getting mypy errors that I think are cache related. The error goes away after
rm -rf .mypy_cache
Here's the smallest repro I could make:
src/zg/foo.py:
src/zg/bar.py:
I am able to reliably hit the problem by running the following commands:
mypy-zope==0.3.9
andtwisted[tls]==22.4.0