question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to run Urs.py

See original GitHub issue

When attempting to run Urs.py I receive the following error. noah@noahdesktop ~/S/U/urs> ./Urs.py -h Traceback (most recent call last): File "/home/noah/Scrapers/URS-master/urs/./Urs.py", line 30, in <module> from urs.utils.Logger import LogMain ModuleNotFoundError: No module named 'urs'

Machine Specs

  • OS: [e.g. Arch Linux x86_64]
  • Python: [e.g. Python 3.8.2]
  • PRAW: [e.g. PRAW 7.0.0]

Additional Context I am unsure if this is due to my own error or not. I am relatively new to python.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
JosephLai241commented, May 8, 2021

My apologies for the late response. After doing some research, it seems the issue could be related to your PYTHONPATH. Try running this line within your shell:

python3 -c "import os, sys; print(os.environ['PYTHONPATH']); print(sys.path) if 'PYTHONPATH' in sorted(os.environ) else print('PYTHONPATH is not defined')"

Running the command will print a list containing directories where Python will look for modules. If your PYTHONPATH is not set, it will print “PYTHONPATH is not defined”.

If the path to where URS is saved on your machine is not in the list, try adding it to PYTHONPATH. Here is a link that explains how to do so for each operating system.

1reaction
SDU-RenHaicommented, May 8, 2021

You should run setup.py first.

Read more comments on GitHub >

github_iconTop Results From Across the Web

python: can't open file 'setup.py': [Errno 2] No such file ... - GitHub
This means that your setuptools are out of date. You can fix this by doing: pip install --upgrade setuptools.
Read more >
Django migration relation does not exist - Stack Overflow
When I run makemigrations, it fails on the first model with relation XXX does not exist. I commented out the code in urls.py...
Read more >
Why does Python in Linux require the line #!/usr/bin/python?
In my prepared and tested example, running hello3m.py as an executable script has failed and returned an error. $ ./hello3m.py ./hello3m.py: ...
Read more >
How to solve “Unable to locate a Java Runtime that supports ...
Try to run caver_analyst with the --jdkhome switch, followed by (I guess) the path to a valid JDK as suggested in your error...
Read more >
Downloading ASDC Data with Python 3 - Earthdata Forum
To check Python's version, simply launch the Python application and ... an existing token by going to https://urs.earthdata.nasa.gov/ and ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found