I am having my project structure like this
ab_folder
---ab.py
---abc.py
ab_report
---ab_report.py
---utils.py
My main file is ab.py in ab_folder which uses abc.py file plus it also imports file ab_report.py file from ab_report folder. I am using the following code in ab.py to switch and import method of ab_report folder
import sys
sys.path.insert(0, "../ab_report")
from ab_report import PDFRepoort
Now currently I am generated exe's of my ab.py file(which is my main file) using pyinstaller.
While reading pyinstaller docs I understand that we have to give directory via --paths arguments if our code changes sys.path.
SO My current directory is ab_folder and in this directory i opened my console and did run the following line to generate ab.spec file
pyi-makespec --paths=C:\Users\abc\Desktop\Deploy_Exe_Test\ab_report ab.py
After this i do run pyinstaller ab.py command to generate exe in dist folder but when I run that exe I get error that
No module named ab_report
I think my issues maybe lies in giving path parameter. Looking for valuable suggestions and help. Also how much this generated exe will be securable(Hard to reverse)?
My python version is 3.6.6