ImportError with cx_Freeze and pyinstaller

自作多情 提交于 2019-11-30 15:20:12

Add pkg_resources to your includes in your setup.py for cx_Freeze.

I had the same issue with cx_freeze. None of the above solutions seemed to work in my case. For me this solution from here worked :

You need to actually create zope/__init__.py as an empty file so that the normal processing performed by imp.find_module() actually works

Try adding to build_exe_options a specific include of the subpackage i.e. "includes": ["zope.interface"], this should force the inclusion of it.

When I add 'pkg_resources' in includes and run the cx_freeze script, I only get these first two lines and it stays here :

running build

running build_exe

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!