Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/cplusplus/145.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python cx\U冻结:无法输入ExcelFormulaParser_Python_Excel_Cx Freeze_Xlwt - Fatal编程技术网

Python cx\U冻结:无法输入ExcelFormulaParser

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

因此,我尝试使用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(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")])