This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author SylvieLorxu
Recipients Kwpolska, SylvieLorxu
Date 2016-07-24.15:46:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1469375177.67.0.287991264427.issue27607@psf.upfronthosting.co.za>
In-reply-to
Content
If main imports another file, and this file imports an Enum class from main, isinstance will return false for Enum variables set in this file, causing the Enums to never match.

A proof of concept is added as a zip. I thank Kwpolska for simplifying my initial proof of concept.

To test this, unzip both files into the same directory and launch main.py with Python 3. I have succesfully been able to reproduce this issue on Python 3.4.3.

From discussion on IRC with Vgr, PEP 499 may be related to this issue: https://www.python.org/dev/peps/pep-0499/.
History
Date User Action Args
2016-07-24 15:46:17SylvieLorxusetrecipients: + SylvieLorxu, Kwpolska
2016-07-24 15:46:17SylvieLorxusetmessageid: <1469375177.67.0.287991264427.issue27607@psf.upfronthosting.co.za>
2016-07-24 15:46:17SylvieLorxulinkissue27607 messages
2016-07-24 15:46:17SylvieLorxucreate