Am trying to get a simple get_bars call, using Python api (api_version = ‘v2’), but it fails with obscure unexplainable error below. The call is done during market open hours.
alpaca_trade_api.rest.APIError: end is too late for subscription
The call is done using code below:
data = api.get_bars(symbol, TimeFrame.Minute, today, tomorrow, adjustment=‘raw’).df
symbol is valid ticker, today equal to today’s date in yyyy-mm-dd format, tomorrow to tomorrow’s date in the same format.
Any ideas? Very few parameters, so not sure what is going wrong.
Thanks a lot.