我几乎花了很多时间试图让bloomberg API与我的Python2.7安装一起工作,但仍然没有成功。Bloomberg HelpDesk不再支持它,因此没有他们的帮助。任何帮助都是非常感谢的:
C:\Users\user>python
Python 2.7.16rc1 (v2.7.16rc1:baacaac06f, Feb 16 2019, 22:56:10) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import blpapi
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python27\lib\site-packages\blpapi\__init__.py", line 11, in <module>
raise debug_load_error(error)
ImportError:
---------------------------- ENVIRONMENT -----------------------------
Platform: Windows-7-6.1.7601-SP1
Architecture: ('64bit', 'WindowsPE')
Python: 2.7.16rc1 (v2.7.16rc1:baacaac06f, Feb 16 2019, 22:56:10) [MSC v.1500 64 bit (AMD64)]
Python implementation: CPython
blpapi 64-bit will be loaded from: "C:\blp\blpapi_cpp_3.12.3.1\bin\blpapi3_64.dll"
blpapi 32-bit will be loaded from: "C:\blp\blpapi_cpp_3.12.3.1\bin\blpapi3_32.dll"
System PATH: (* marks locations where blpapi was found)
"C:\Program Files\Java\jdk-12.0.2\bin"
"C:\Python27\"
"C:\Python27\Scripts"
"C:\Windows\system32"
"C:\Windows"
"C:\Windows\System32\Wbem"
"C:\Windows\System32\WindowsPowerShell\v1.0\"
* "C:\blp\blpapi_cpp_3.12.3.1\bin"
blpapi package at: "C:\Python27\lib\site-packages"
Current directory: "C:\Users\user"
----------------------------------------------------------------------
No module named _versionhelper
Could not open the C++ SDK library.
Download and install the latest C++ SDK from:
http://www.bloomberg.com/professional/api-library
If the C++ SDK is already installed, please ensure that the path to the library
was added to PATH before entering the interpreter.发布于 2020-04-09 21:09:58
发布于 2020-10-27 21:44:13
我做了两件事来解决类似的问题:
1-我安装了Microsoft Visual Studio,确保具有以下组件:
2-我手动将C++API\lib中的.dll文件(在我的例子中是blpapi3_32.dll和blpapi3_64.dll )复制到C:\windows\system32,系统使用的所有dll文件都在C:\windows\SYSTEM32中。
另外,我将C++API\lib中的dll文件复制到C:\blp\DAPI中,用旧文件替换新文件。
不知何故,Path变量不够成功,无法在API文件夹中找到dll。
https://stackoverflow.com/questions/58896429
复制相似问题