0

我想将我的包设置为 Pypi。当我跑

python setup.py sdist bdist_wininst upload

出现这个错误:

  File "setup.py", line 8, in <module>
    long_description=open('README.txt').read(),
  File "/usr/lib/python2.7/distutils/core.py", line 152, in setup
    dist.run_commands()
  File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/usr/lib/python2.7/distutils/command/bdist_wininst.py", line 189, in run
    self.create_exe(arcname, fullname, self.bitmap)
  File "/usr/lib/python2.7/distutils/command/bdist_wininst.py", line 271, in create_exe
    file.write(self.get_exe_bytes())
  File "/usr/lib/python2.7/distutils/command/bdist_wininst.py", line 366, in get_exe_bytes
    raise DistutilsFileError, str(msg) + ', %s not included in the Debian packages.' % filename
NameError: global name 'DistutilsFileError' is not defined

我该如何解决这个错误?

4

1 回答 1

1

似乎存在与您在启动板上的体验相关的错误。看这里

您可以通过尝试解决方案来解决问题吗?

取自页面:

可以通过在导入部分(bdist_wininst.py 文件的第 17 行)添加 DistutilsFileError 来纠正此错误

于 2013-04-23T12:38:52.290 回答