Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error when calling LightTimeSeriesFactor with Bloomberg #5

Open
toimfortes opened this issue Mar 31, 2016 · 3 comments
Open

error when calling LightTimeSeriesFactor with Bloomberg #5

toimfortes opened this issue Mar 31, 2016 · 3 comments

Comments

@toimfortes
Copy link

df = ltsf.harvest_time_series(time_series_request)
Traceback (most recent call last):
File "", line 1, in
File "C:\Anaconda2\lib\site-packages\pythalesians-0.1a0-py2.7.egg\pythalesians\market\loaders\lighttimeseriesfactory.py", line 126, in harvest_time_series
loader = self.get_loader(time_series_request.data_source)
File "C:\Anaconda2\lib\site-packages\pythalesians-0.1a0-py2.7.egg\pythalesians\market\loaders\lighttimeseriesfactory.py", line 93, in get_loader
loader = LoaderBBGOpen()
File "C:\Anaconda2\lib\site-packages\pythalesians-0.1a0-py2.7.egg\pythalesians\market\loaders\lowlevel\bbg\loaderbbgopen.py", line 41, in init
super(LoaderBBGOpen, self).init()
TypeError: must be type, not classobj

@saeedamen
Copy link
Contributor

Hi @toimfortes, thanks for flagging this. First, I'd recommend downloading the newest dev version of PyThalesians from GitHub, as opposed to the last release (which is now quite old). Also, the library is built for Python 3, so it is unlikely to be compatible with Python 2 (I suspect this is the problem you are having looking at the code). Regards Saeed

@Heavy-Sauria
Copy link

Hi,
I am getting the same error, therefore I switched to Python3 however the Bloomberg Python SDK is not compatible with Python3.

#!/usr/bin/env python

"""
setup.py file for Bloomberg Python SDK
"""

from distutils.core import setup, Extension
import os
import platform as plat
from sys import version
from sys import platform

if version < '2.6':
    raise Exception(
        "Python versions before 2.6 are not supported (current version is " +
    version + ")")
if version >= '3.0':
    raise Exception(
        "Python 3 is not supported (current version is " + version +
        ")")

Regards,
Robert

@saeedamen
Copy link
Contributor

Hi @csango - I think you have an old version of the Bloomberg Python API from the look of it. The newer versions are compatible with Python 3. You can download these from http://www.bloomberglabs.com/api/libraries/ - if you have Python 3.5, you'll need to compile it however (I've got a precompiled version though, if you have trouble :-). For all other Python versions, Bloomberg have provided easy to install binaries. Regards Saeed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants