You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 24, 2021. It is now read-only.
$ lx
Traceback (most recent call last):
File "/bin/lx", line 3, in
from lixian_commands.util import *
ImportError: No module named lixian_commands.util
to fix this issue, I have to modify lixian_cli.py a little bit:
!/usr/bin/env python
import sys
define base path, where the path has to be adapted to the real directory
sys.path.append('/usr/share/xunlei-lixian')
from lixian_commands.util import *
import lixian_help
The text was updated successfully, but these errors were encountered:
This is not the correct way to do it. It should not be assumed that xunlei-lixian will be installed to /usr/share for everyone, but rather it's a local administrator's choice (should xunlei-lixian be installed site-wide)
If you intend to this , you should append "/usr/share/xunlei-lixian" to PYTHONPATH in your shell environment.
moving lx executable to /bin is just plain wrong, you should symlink it instead.
I agree that it should be site-wide where xunlei-lixian would be installed.
The issue is that, I'm not familiar with Python, and when I follow the README instruction provided, I encountered the error message. It took me a while to figure out it was a "path" issue and I was not aware of PYTHONPATH until you mentioned it.
At least, it should be a "setup" step to append the xunlei-lixian path to the environment variable PYTHONPATH before linking xunlei-lixian_cli.py to /bin/lx and attempting to execute it, or, provide a clear HowTo instruction for Python novice users.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
$ lx
Traceback (most recent call last):
File "/bin/lx", line 3, in
from lixian_commands.util import *
ImportError: No module named lixian_commands.util
to fix this issue, I have to modify lixian_cli.py a little bit:
!/usr/bin/env python
import sys
define base path, where the path has to be adapted to the real directory
sys.path.append('/usr/share/xunlei-lixian')
from lixian_commands.util import *
import lixian_help
The text was updated successfully, but these errors were encountered: