PyInstaller failing to include some modules from C:\Python27\Lib

前端 未结 3 1833
野趣味
野趣味 2021-02-06 11:40

I\'ve been repeatedly making good PyInstaller executables of a Tkinter utility program, and suddenly this morning the resulting executable fails with a \"can\'t import\" error f

3条回答
  •  别那么骄傲
    2021-02-06 12:41

    Found a fix, if not the cause. Here's my updated build line:

    pyinstaller --hidden-import=timeit --hidden-import=bisect -F MyMainModule.py
    

    Still not sure why PyInstaller suddenly forgot how to find these two modules (and only these two modules) among over 20 other modules correctly included in the build.

提交回复
热议问题