简体   繁体   中英

Python error: ImportError: No module named src.core.setcore?

Hey guys I'm new here and I have found no solution to my problem yet. I am currently learning to program in C but I don't know much about python, and what happens is that when I try to run a script it gives me this error:

 root@ubuntu:/usr/share/set/src/core# ./fasttrack.py 

Traceback (most recent call last): 
File "./fasttrack.py", line 2, in <module>
from src.core.setcore import *
ImportError: No module named src.core.setcore

Can someone tell what's happening here so I can fix this problem? (I'm using ubuntu terminal just in case.) Thanks in advance.

Try running the script from a directory two levels up the tree.

root@ubuntu:/usr/share/set# ./fasttrack.py

The import statements encountered in python search for modules relative to the current directory and the directories in the Python path.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM