linux系统python运行脚本时正常,但是用打包后运行就出现了错误????? 100
找到了原因,但不知道怎么解决。是frompymouseimportPyMouse这句话提示的以下错误:Traceback(mostrecentcalllast):File...
找到了原因,但不知道怎么解决。是from pymouse import PyMouse这句话提示的以下错误:
Traceback (most recent call last):
File "<string>", line 3, in <module>
File "/home/jeff/下载/PyInstaller-2.1/PyInstaller/loader/pyi_importers.py", line 270, in load_module
exec(bytecode, module.__dict__)
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/pymouse", line 95, in <module>
File "/home/jeff/下载/PyInstaller-2.1/PyInstaller/loader/pyi_importers.py", line 270, in load_module
exec(bytecode, module.__dict__)
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/pymouse.unix", line 25, in <module>
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.display", line 83, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.display", line 65, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.protocol.display", line 44, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.support.connect", line 64, in get_display
ImportError: No module named unix_connect
再次说明,用脚本运行时能够正常运行,打包后就出现了错误,为什么就没有包含了这个模块,该怎样包含?????????
from pymouse import PyMouse
m = PyMouse()
print m.position()
这是我的脚本。
运行脚本没有一点错误,pyinstaller 打包后就出现了错误。换了其他打包软件也不行 展开
Traceback (most recent call last):
File "<string>", line 3, in <module>
File "/home/jeff/下载/PyInstaller-2.1/PyInstaller/loader/pyi_importers.py", line 270, in load_module
exec(bytecode, module.__dict__)
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/pymouse", line 95, in <module>
File "/home/jeff/下载/PyInstaller-2.1/PyInstaller/loader/pyi_importers.py", line 270, in load_module
exec(bytecode, module.__dict__)
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/pymouse.unix", line 25, in <module>
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.display", line 83, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.display", line 65, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.protocol.display", line 44, in __init__
File "/home/jeff/下载/PyInstaller-2.1/sss/build/sss/out00-PYZ.pyz/Xlib.support.connect", line 64, in get_display
ImportError: No module named unix_connect
再次说明,用脚本运行时能够正常运行,打包后就出现了错误,为什么就没有包含了这个模块,该怎样包含?????????
from pymouse import PyMouse
m = PyMouse()
print m.position()
这是我的脚本。
运行脚本没有一点错误,pyinstaller 打包后就出现了错误。换了其他打包软件也不行 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询