[英]cx_Freeze ImportError: DLL load failed failed while importing _ctypes: The specified module could not be found
I compiled some Python scripts with cx_Freeze but compiled scripts giving me this error:我用 cx_Freeze 编译了一些 Python 脚本,但编译的脚本给了我这个错误:
setup.py:
from cx_Freeze import setup, Executable
executables = [
Executable('USBAIO.py', base="Win32GUI", icon="Icons\\icon.ico"),
Executable('ui.py', base="Win32GUI", icon="Icons\\icon.ico"),
Executable("formatter.py", base="Win32GUI", icon="Icons\\cicon.ico"),
Executable("updater.py", base="Win32GUI", icon="Icons\\uicon.ico"),
Executable("permremove.py", base="Win32GUI", icon="Icons\\cicon.ico")
]
Packages = ["tkinter","functools", "time", "win32api",
"threading", "subprocess", "psutil", "os",
"shutil", "re", "requests", "sys", "ctypes",
"argparse", "google_drive_downloader",
"win32file", "win32con"
]
Include = ["Icons", "version.txt", "icon.ico"]
setup(
name="myapp",
options={"build_exe":{"packages":Packages,"include_files":Include}},
description = "myapp",
executables = executables
)
Python version: 3.8
Python 版本:3.8
Windows: 8.1 Pro WMC
Windows:8.1 专业版 WMC
cx_Freeze: 6.0b1
cx_Freeze:6.0b1
I had the same issue.我遇到过同样的问题。 It was caused by using conda install pyqt.
这是由使用 conda install pyqt 引起的。
Uninstalling it and reinstalling using conda install -c anaconda pyqt fixed it.卸载它并使用 conda install -c anaconda pyqt 重新安装修复它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.