Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with unittest.pyi (typeshed too old?) #45

Closed
nodakai opened this issue Feb 6, 2017 · 3 comments
Closed

Error with unittest.pyi (typeshed too old?) #45

nodakai opened this issue Feb 6, 2017 · 3 comments

Comments

@nodakai
Copy link
Contributor

nodakai commented Feb 6, 2017

A one-line test case ut.py

import unittest

resulted in this error::

File "ut.py", line 1, in <module>: Couldn't import pyi for 'unittest' [pyi-error]
    File: "/pxfs/dev/nodakai/og-py27/lib/python2.7/site-packages/pytype/typeshed/stdlib/2.7/unittest.pyi", line 30
      shouldStop = False
                   ^
  ParseError: syntax error, unexpected NAME, expecting NUMBER or ELLIPSIS

pytype Git HEAD 4e164cc

@matthiaskramm
Copy link
Contributor

Try

shouldStop = ...  # type: bool

@nodakai
Copy link
Contributor Author

nodakai commented Feb 7, 2017

It's already fixed in the upstream, python/typeshed@746f4db
Why is pytype still using the May 17 version of typeshed?

@matthiaskramm
Copy link
Contributor

Updated typeshed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants