Cannot find reference 'get_open_orders' in 'api.pyi'


#1

Hi,

in the example buy_and_hodl I get the precompile error:

Cannot find reference ‘get_open_orders’ in ‘api.pyi’

Script running anyway, the statements

orders = get_open_orders(context.asset) or []
for order in orders:
cancel_order(order)

are executed, anyway.

Debugging shows that list of open orders appears to be empty. Unclear, if this is because the get_open_orders() doesn’t work due to the compile error.

Did not find this method in the api reference, also. Maybe it belongs to a different class?


#2

Hi @Ernestopheles, Thanks for bringing this up, the function get_open_orders indeed is not defined in api.pyi, but works fine without it - so it was added there (in develop branch) and will appear in our next release.

Thanks!