Tôi đang ở trong Windows, sử dụng pyInstaller để đóng gói tệp python. Nhưng một cái gì đó xảy ra lỗi:pyInstaller: Lỗi nhập
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "D:\Useful Apps\pyinstaller-2.0\PyInstaller\loader\iu.py", line 386, in i
mportHook
mod = _self_doimport(nm, ctx, fqname)
File "D:\Useful Apps\pyinstaller-2.0\PyInstaller\loader\iu.py", line 480, in d
oimport
exec co in mod.__dict__
File "D:\Useful Apps\pyinstaller-2.0\server\build\pyi.win32\server\out00-PYZ.p
yz\SocketServer", line 132, in <module>
File "D:\Useful Apps\pyinstaller-2.0\PyInstaller\loader\iu.py", line 386, in i
mportHook
mod = _self_doimport(nm, ctx, fqname)
File "D:\Useful Apps\pyinstaller-2.0\PyInstaller\loader\iu.py", line 480, in d
oimport
exec co in mod.__dict__
File "D:\Useful Apps\pyinstaller-2.0\server\build\pyi.win32\server\out00-PYZ.p
yz\socket", line 47, in <module>
File "D:\Useful Apps\pyinstaller-2.0\PyInstaller\loader\iu.py", line 409, in i
mportHook
raise ImportError("No module named %s" % fqname)
ImportError: No module named _socket
Tôi biết rằng _socket
là trong con đường C:\Python27\libs\_socket.lib
, nhưng làm thế nào có thể để cho các EXE
tìm tập tin đó?