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

how to use snoop for python 2.7 #69

Open
sant527 opened this issue Feb 13, 2024 · 1 comment
Open

how to use snoop for python 2.7 #69

sant527 opened this issue Feb 13, 2024 · 1 comment

Comments

@sant527
Copy link

sant527 commented Feb 13, 2024

I am getting the below error when using snoop. when trying to run in python 2.7

how to use snoop for python 2.7

  File "/home/hadoop/./driver.py", line 1, in <module>
    import snoop
  File "/usr/local/lib/python2.7/site-packages/snoop/__init__.py", line 19, in <module>
    from .configuration import Config, install
  File "/usr/local/lib/python2.7/site-packages/snoop/configuration.py", line 11, in <module>
    from snoop.formatting import DefaultFormatter
  File "/usr/local/lib/python2.7/site-packages/snoop/formatting.py", line 8, in <module>
    import executing
  File "/usr/local/lib/python2.7/site-packages/executing/__init__.py", line 12, in <module>
    from .executing import Source, Executing, only, NotOneValueFound, cache, future_flags
  File "/usr/local/lib/python2.7/site-packages/executing/executing.py", line 36, in <module>
    from functools import lru_cache
ImportError: cannot import name lru_cache
$ pip show snoop
Name: snoop
Version: 0.4.3
Summary: Powerful debugging tools for Python
Home-page: https://github.com/alexmojaki/snoop
Author: Alex Hall
Author-email: [email protected]
License: MIT
Location: /usr/local/lib/python2.7/site-packages
Requires: cheap-repr, asttokens, backports.functools-lru-cache, six, pygments, executing
You are using pip version 9.0.3, however version 24.0 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
python --version
Python 2.7.18

pip -V
pip 9.0.3 from /usr/lib/python2.7/dist-packages (python 2.7)
@alexmojaki
Copy link
Owner

Check pip show executing. It needs to be before 2.0.0.

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