Python cx\U冻结:无法输入ExcelFormulaParser
因此,我尝试使用cx\U freeze将代码编译成.exe 这是我用来编译它的代码Python cx\U冻结:无法输入ExcelFormulaParser,python,excel,cx-freeze,xlwt,Python,Excel,Cx Freeze,Xlwt,因此,我尝试使用cx\U freeze将代码编译成.exe 这是我用来编译它的代码 from cx_Freeze import setup, Executable import sys import numpy.core._methods import numpy.lib.format from xlwt import ExcelFormulaParser additional_mods = ['numpy.core._methods', 'numpy.lib.format'] setup
from cx_Freeze import setup, Executable
import sys
import numpy.core._methods
import numpy.lib.format
from xlwt import ExcelFormulaParser
additional_mods = ['numpy.core._methods', 'numpy.lib.format']
setup(name='ReconApp',
version='0.1',
description='xyz.script',
options = {'build_exe': {'includes': additional_mods}},
executables = [Executable("reconciliation_application.py")])
代码编译时没有错误。
当我运行.exe时,程序启动并关闭,出现此错误
我注意到它不喜欢xlwt模块ExcelFormulaParser中的某些内容
我不知道是什么错误
有什么建议吗?尝试将xlwt库添加到设置选项中,即
import sys, os
from cx_Freeze import setup, Executable
build_exe_options = {"packages": ["numpy", "matplotlib", "xlwt"]}
setup(
name = "App",
version = "1.0",
description = "App ...",
options = {"build_exe": build_exe_options},
executables = [Executable("App.py", base = "Win32GUI")])