gpt4 book ai didi

Python M2Crypto DLL 加载失败,找不到指定的模块

转载 作者:行者123 更新时间:2023-12-01 15:14:21 26 4
gpt4 key购买 nike

我正在尝试将此切片用于我的 web2py 应用程序 http://www.web2pyslices.com/slices/take_slice/106

我安装了模块 M2Crypto 并跟随切片,当加载页面时我收到此错误

Traceback (most recent call last):
File "F:\Projects\Web2py\w1992\gluon\restricted.py", line 194, in restricted
exec ccode in environment
File "F:\Projects\Web2py\w1992\applications\internet2letter\views\account/order.html", line 102, in <module>
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 294, in __call__
fromlist, level)
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 78, in __call__
level)
File "applications\internet2letter\modules\crypt.py", line 2, in <module>
from M2Crypto import BIO, SMIME, X509, EVP
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 294, in __call__
fromlist, level)
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 78, in __call__
level)
File "C:\Python27\lib\site-packages\M2Crypto\__init__.py", line 22, in <module>
import __m2crypto
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 294, in __call__
fromlist, level)
File "F:\Projects\Web2py\w1992\gluon\custom_import.py", line 78, in __call__
level)
ImportError: DLL load failed: Das angegebene Modul wurde nicht gefunden.

所以我尝试直接从 Python 导入模块我打开终端并输入

>>> import M2Crypto
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python27\lib\site-packages\M2Crypto\__init__.py", line 23, in <module
>
import m2
File "C:\Python27\lib\site-packages\M2Crypto\m2.py", line 28, in <module>
from __m2crypto import *
ImportError: DLL load failed: Das angegebene Modul wurde nicht gefunden.
>>>

无论如何要解决这个问题??

最佳答案

有同样的问题,通过从这里安装 OpenSSL for Windows 修复它:http://slproweb.com/products/Win32OpenSSL.html

我将 OpenSSL v1.0.1b(安装到系统目录的 DLL)与 M2Crypto 0.21.1 和 Python 2.7.3(所有 32 个版本)一起使用没问题。

关于Python M2Crypto DLL 加载失败,找不到指定的模块,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8908625/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com