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

cli doesn't finds the module #68

Open
Nama opened this issue Oct 27, 2023 · 4 comments
Open

cli doesn't finds the module #68

Nama opened this issue Oct 27, 2023 · 4 comments
Assignees

Comments

@Nama
Copy link

Nama commented Oct 27, 2023

Describe the bug
Installing in a venv and running wallgen errors like this:

$ wallgen
Traceback (most recent call last):
  File "/home/yama/venv/wallgen/bin/wallgen", line 5, in <module>
    from wallgen import cli
ModuleNotFoundError: No module named 'wallgen'

Desktop (please complete the following information):

  • 6.5.9-zen2-1-zen
  • Arch Linux
  • Python 3.11.5

Workaround
python -m wallgen pic shape ...

@SubhrajitPrusty
Copy link
Owner

Seems like you are using a virtualenv to install the package. You would need to add the path to PATH for the cli to work. ref

@SubhrajitPrusty SubhrajitPrusty self-assigned this Oct 28, 2023
@Nama
Copy link
Author

Nama commented Oct 28, 2023

But the venv is active...

$ wallgen
bash: wallgen: command not found
$ source venv/wallgen/bin/activate
$ wallgen
Traceback (most recent call last):
  File "/home/yama/venv/wallgen/bin/wallgen", line 5, in <module>
    from wallgen import cli
ModuleNotFoundError: No module named 'wallgen'
$ which wallgen
/home/yama/venv/wallgen/bin/wallgen

@SubhrajitPrusty
Copy link
Owner

I cannot reproduce this. Can you try installing the module without --editable flag?

@Nama
Copy link
Author

Nama commented Oct 29, 2023

Same error.
Idk, if nobody else is having this issue, must be me. And I'm fine with using python -m wallgen ....

One thing I noticed, is that your module is in the root of the repository. And after checking my venv, I noticed that all modules have two folders in lib/python3.11/site-packages/:

...
click
click-8.1.7.dist-info
...

wallgen only has one folder: wallgen-1.0.dist-info
All the files which should be in the wallgen folder are in the tools folder.

You might consider putting everything in a subfolder.

You can close this if you don't want to investigate any further.

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