[issue34175] typing.NamedTuple: type-checking error when "index" used as member

2018-07-21 Thread Keith Campbell
Keith Campbell added the comment: > It's up to the OP to file an issue there though Will do; thanks! -- ___ Python tracker ___

[issue34175] typing.NamedTuple: type-checking error when "index" used as member

2018-07-20 Thread Guido van Rossum
Guido van Rossum added the comment: > Perhaps this report should go on the mypy bug tracker rather than the Python > language tracker. Agreed. It's up to the OP to file an issue there though (hence adding @campkeith back to the nosy list). -- nosy: +campkeith resolution: -> third

[issue34175] typing.NamedTuple: type-checking error when "index" used as member

2018-07-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: > So I suspect this is a bug in the type checker. Perhaps this report should go on the mypy bug tracker rather than the Python language tracker. -- nosy: +gvanrossum, levkivskyi, rhettinger -campkeith ___

[issue34175] typing.NamedTuple: type-checking error when "index" used as member

2018-07-20 Thread Keith Campbell
New submission from Keith Campbell : Find the test case below: from typing import NamedTuple class Foo(NamedTuple): alpha: int index: int This results in the following error when run through type-checking with mypy: % mypy --version mypy 0.620 % mypy go.py go.py:5: