Author mjpieters
Recipients mjpieters
Date 2016-03-03.18:11:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Sorry, that should have read "the forward references section of PEP 484".

The section uses this example:

# File models/
from models import b
class A(Model):
    def foo(self, b: 'b.B'): ...

# File models/
from models import a
class B(Model):
    def bar(self, a: 'a.A'): ...

# File
from models.a import A
from models.b import B

which doesn't fail because the forward references are not being tested until after all imports have completed; creating a Union however triggers a subclass test between the different types in the union.
Date User Action Args
2016-03-03 18:11:39mjpieterssetrecipients: + mjpieters
2016-03-03 18:11:39mjpieterssetmessageid: <>
2016-03-03 18:11:39mjpieterslinkissue26477 messages
2016-03-03 18:11:39mjpieterscreate