I am trying to run my python3
code distributable
, with a single executable
, mostly in Linux
and mac
system.
My file structure is:
mkbib
├── main.py
├── menubar.ui
├── menu.py
├── mkbib.svg
├── pybib.py
├── __pycache__
│ ├── main.cpython-34.pyc
│ ├── menu.cpython-34.pyc
│ ├── pybib.cpython-34.pyc
│ └── view.cpython-34.pyc
└── view.py
setup.py [error opening dir]
This runs fine with
$python3 main.py
But, as I was trying to setup setup.py
(comment in this Q) I come to realize that, I should run it using
python3 -m mkbib.main
(not exactly sure why), but when I try this, I am getting error:
python3 -m mkbib.main
Traceback (most recent call last):
File "/usr/lib64/python3.4/runpy.py", line 170, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib64/python3.4/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/home/rudra/Devel/mkbib/Python/mkbib/main.py", line 3, in <module>
import menu
ImportError: No module named 'menu'
Is this a basic problem with the code itself? Or I need to follow few things that I am missing?