V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
bspeng922
V2EX  ›  Python

pyinstaller 打包 pyqt4 老是有问题

  •  
  •   bspeng922 · 2016-05-09 16:37:18 +08:00 · 3751 次点击
    这是一个创建于 2930 天前的主题,其中的信息可能已经有所发展或是发生改变。
    使用 pyinstaller 打包 pyqt4 代码, exe 文件能正常生成,不过执行 exe 文件的时候总是提示 'setuptools' distribution was not found ,

    我 setuptools 是肯定装了的, pip show setuptools 也能看到相应信息,实在不知道什么地方有问题了。



    PS :我在网上找了个俄罗斯方块的 qt4 文件,那个可以成功打包,也可以执行,就是我写的那个执行不了,跪求大神帮忙看看有什么问题啊。


    错误信息:
    ···
    D:\PyInstaller-3.1.1\cclient\dist\cclient>cclient.exe
    Traceback (most recent call last):
    File "<string>", line 6, in <module>
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "login.py", line 6, in <module>
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "site-packages\keystoneclient\__init__.py", line 36, in <module>
    File "site-packages\pbr\version.py", line 465, in version_string
    File "site-packages\pbr\version.py", line 460, in semantic_version
    File "site-packages\pbr\version.py", line 446, in _get_version_from_pkg_resour
    ces
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "site-packages\pbr\packaging.py", line 33, in <module>
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "build\bdist.win32\egg\setuptools\command\develop.py", line 9, in <module
    >
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "build\bdist.win32\egg\setuptools\command\easy_install.py", line 48, in <
    module>
    File "D:\PyInstaller-3.1.1\PyInstaller\loader\pyimod03_importers.py", line 389
    , in load_module
    exec(bytecode, module.__dict__)
    File "build\bdist.win32\egg\setuptools\package_index.py", line 203, in <module
    >
    File "build\bdist.win32\egg\pkg_resources\__init__.py", line 962, in require
    File "build\bdist.win32\egg\pkg_resources\__init__.py", line 849, in resolve
    pkg_resources.DistributionNotFound: The 'setuptools' distribution was not found
    and is required by the application
    main returned -1
    ···
    1 条回复    2016-05-09 18:31:02 +08:00
    RqPS6rhmP3Nyn3Tm
        1
    RqPS6rhmP3Nyn3Tm  
       2016-05-09 18:31:01 +08:00 via iPad
    Pyqt5 正常,昨天刚打包。反而 py2app 死活打不了。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2442 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 04:01 · PVG 12:01 · LAX 21:01 · JFK 00:01
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.