模块 'robin_stocks' 没有属性 'get_current_positions'

module 'robin_stocks' has no attribute 'get_current_positions'

这是我第一次使用 robinhood api,我正在试用他们的文档:https://readthedocs.org/projects/robin-stocks/downloads/pdf/latest/, 但是他们的一项关键功能不起作用。当我调用 robin_stocks.get_current_positions() 时出现错误

AttributeError: module 'robin_stocks' has no attribute 'get_current_positions'

这是我的代码:

import robin_stocks, json
from robin_stocks import *
import robin_stocks as r
import sys
import time
import requests

content = open('config.json').read()
config = json.loads(content)

login = r.login(config['username'],config['password'], store_session=True)

my_stocks = robin_stocks.build_holdings()
for key,value in my_stocks.items():
    mystocks = key,value

print(mystocks)

WEIbalance = mystocks[1]['equity']
WEI = mystocks[0]
print('YY', WEI)
positions_data = robin_stocks.get_current_positions()

print('my equity', WEIbalance)
print(positions_data)

这是我的错误吗?

截至目前commit get_current_positions was renamed to get_open_stock_positions() the corresponding issue can be found here