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 GBeauregard
Recipients AlexWaygood, GBeauregard, Gobot1234, JelleZijlstra, gvanrossum, kj, levkivskyi, sobolevn
Date 2022-02-05.20:59:57
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1644094797.07.0.846449398936.issue46644@roundup.psfhosted.org>
In-reply-to
Content
Under the same failing int test cases before there were 2 more cases next to them that fail:

with self.assertRaises(TypeError):
    ClassVar[int, str]
with self.assertRaises(TypeError):
    Final[int, str]

These fail because tuple literals are not callable(). There is code that clearly intends for this to be the case: https://github.com/python/cpython/blob/96b344c2f15cb09251018f57f19643fe20637392/Lib/typing.py#L486

I can either remove support for this runtime check or change the implementation of Final et al to reject tuple literals. I will do the latter for now.

For https://github.com/python/cpython/blob/bf95ff91f2c1fc5a57190491f9ccdc63458b089e/Lib/test/test_typing.py#L4262-L4263 I think the best approach is to just remove these tests.
History
Date User Action Args
2022-02-05 20:59:57GBeauregardsetrecipients: + GBeauregard, gvanrossum, levkivskyi, JelleZijlstra, sobolevn, Gobot1234, kj, AlexWaygood
2022-02-05 20:59:57GBeauregardsetmessageid: <1644094797.07.0.846449398936.issue46644@roundup.psfhosted.org>
2022-02-05 20:59:57GBeauregardlinkissue46644 messages
2022-02-05 20:59:57GBeauregardcreate