【问题标题】:Py2exe missing modules when bundling捆绑时 Py2exe 缺少模块
【发布时间】:2017-05-16 23:39:43
【问题描述】:

在开始之前,我已经检查了这个 question,并且我的 setup.py 中已经有一个 windows=[]。请注意,我将要转换的脚本命名为 Tkinter.py。

这是我的 setup.py:

from distutils.core import setup
import py2exe

setup(
    windows=['Tkinter.py'],
    options={
        "py2exe":{
            "bundle_files":1,

        }
    }
)

这是错误:

C:\Users\Julian\Desktop\Tkinter>python setup.py py2exe
running py2exe

  3 missing Modules
  ------------------
? readline                            imported from cmd, code, pdb
? win32api                            imported from platform
? win32con                            imported from platform
The following modules require a minimum bundle_files option,
otherwise they will not work (currently bundle_files is set to 1):
    tkinter: 2

Please change the bundle_files option and run the build again.
Build failed.

我正在尝试将其全部捆绑到一个 exe 文件中。感谢您的帮助!

【问题讨论】:

    标签: python tkinter py2exe


    【解决方案1】:

    只需忽略缺少模块的问题。他们不会造成任何问题。对于捆绑问题,只需将捆绑值更改为 2 即可。

    【讨论】:

      猜你喜欢
      • 2015-01-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-05-17
      • 1970-01-01
      • 1970-01-01
      • 2019-10-11
      相关资源
      最近更新 更多