Skip to content

getting error #175

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

Closed
omergunal opened this issue Sep 21, 2018 · 5 comments
Closed

getting error #175

omergunal opened this issue Sep 21, 2018 · 5 comments

Comments

@omergunal
Copy link
Contributor

python3 -m pyt x.py

Traceback (most recent call last):
  File "/usr/lib/python3.5/runpy.py", line 184, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/gunal/pyt/pyt/__main__.py", line 10, in <module>
    from .cfg import make_cfg
  File "/home/gunal/pyt/pyt/cfg/__init__.py", line 1, in <module>
    from .make_cfg import make_cfg
  File "/home/gunal/pyt/pyt/cfg/make_cfg.py", line 1, in <module>
    from .expr_visitor import ExprVisitor
  File "/home/gunal/pyt/pyt/cfg/expr_visitor.py", line 31, in <module>
    from .stmt_visitor import StmtVisitor
  File "/home/gunal/pyt/pyt/cfg/stmt_visitor.py", line 58, in <module>
    uninspectable_modules = {module.name for module in iter_modules()}  # Don't warn about failing to import these
  File "/home/gunal/pyt/pyt/cfg/stmt_visitor.py", line 58, in <setcomp>
    uninspectable_modules = {module.name for module in iter_modules()}  # Don't warn about failing to import these
AttributeError: 'tuple' object has no attribute 'name'
@KevinHock
Copy link
Collaborator

What is x.py?

@omergunal
Copy link
Contributor Author

I tried to scan x.py file

@KevinHock
Copy link
Collaborator

Run cat x.py

@bcaller
Copy link
Collaborator

bcaller commented Sep 21, 2018

You are running pyt with python 3.5.

Try running it in a python 3.6 environment.

@omergunal
Copy link
Contributor Author

@KevinHock

cat x.py 
x = (1,2,3)

a = {i for i in x}

print(a)

@bcaller yes, it worked with python3.6

@bcaller bcaller closed this as completed Sep 22, 2018
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

3 participants