oanda / v20-python

OANDA v20 bindings for Python
MIT License
225 stars 91 forks source link

AttributeError: 'Context' object has no attribute 'primitives' #13

Closed alekna closed 7 years ago

alekna commented 8 years ago

Getting AttributeError in 3.0.11 Used to work fine with 3.0.9

>>> ctx = v20.Context('api-fxtrade.oanda.com', token=access_token)
>>> ctx.account.instruments(account_id)
Traceback (most recent call last):
  File "<input>", line 1, in <module>
    ctx.account.instruments(account_id)
  File "/usr/lib/python3.5/site-packages/v20/account.py", line 1128, in instruments
    for d in jbody.get('instruments')
  File "/usr/lib/python3.5/site-packages/v20/account.py", line 1128, in <listcomp>
    for d in jbody.get('instruments')
AttributeError: 'Context' object has no attribute 'primitives'
dmpettyp commented 8 years ago

Thanks, I'll take a look