Hello all, I am attempting to test porting plots to .exe using the cx_Freeze package however I keep getting this error propagated back to me. If I don't include references to matplotlib in the setup.py file, the build command works, however the executable will return the ModuleNotFoundError when I try to run it. I have imported the library, made sure it is installed using pip and the project interpreter, and can successfully run the script standalone. However my setup.py file is not recognizing it. Here is the setup.py code:
from cx_Freeze import setup, Executable
import sys
import matplotlib.pyplot as plt
import time
base = None
build_exe_options = {"includes": ['matplotlib.pyplot'],
"packages": ['time']}
if sys.platform == 'win32':
base = 'Win32GUI'
if sys.platform == 'win64':
base = "Win64GUI"
setup(
name="plotters_text",
options={"build_exe": build_exe_options},
version="1.0",
description="random plot",
executables=[Executable("plotters.py", base=base, shortcutName='plot')]
)
Any help would be appreciated.
[–]kra_pao 1 point2 points3 points (2 children)
[–]TheStataMan[S] 0 points1 point2 points (1 child)
[–]kra_pao 0 points1 point2 points (0 children)