Hi Brian,
Since about two weeks ago, I've been getting this error when trying to ingest my IBKR minute database into a zipline bundle:
quantrocket_houston_1|172.18.0.2 - - [23/Nov/2021:01:42:28 +0000] "GET /zipline/bundles HTTP/1.1" 200 52 "-" "-"
quantrocket_houston_1|172.18.0.2 - - [23/Nov/2021:01:42:28 +0000] "GET /zipline/bundles HTTP/1.1" 200 52 "-" "-"
quantrocket_houston_1|172.18.0.2 - - [23/Nov/2021:01:42:29 +0000] "PUT /zipline/bundles/ibkr-minute-bundle?ingest_type=from_db&from_db=ibkr-minute-db&calendar=NYSE&start_date=09-28-2021 HTTP/1.1" 200 79 "-" "-"
quantrocket_houston_1|172.18.0.2 - - [23/Nov/2021:01:42:29 +0000] "POST /zipline/ingestions/ibkr-minute-bundle HTTP/1.1" 202 55 "-" "-"
quantrocket_flightlog_1|2021-11-22 17:42:29 quantrocket.zipline: INFO [ibkr-minute-bundle] Ingesting ibkr-minute-bundle bundle
quantrocket_zipline_1|Ingesting 13260 minute bars for A STK (sid FIBBG000C2V3D6)
quantrocket_zipline_1|error ingesting A STK (sid FIBBG000C2V3D6)
quantrocket_zipline_1|Traceback (most recent call last):
quantrocket_zipline_1| File "sym://qrocket_qrzipline_bundles_fromdb_minute_py", line 279, in _consume_prices
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/zipline/data/resample.py", line 65, in minute_frame_to_session_frame
quantrocket_zipline_1| labels = calendar.minute_index_to_session_labels(minute_frame.index)
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/trading_calendars/trading_calendar.py", line 1053, in minute_index_to_session_labels
quantrocket_zipline_1| self._opens.values.searchsorted(index.values, side="right") - 1
quantrocket_zipline_1|TypeError: '<' not supported between instances of 'int' and 'Timestamp'
quantrocket_zipline_1|
quantrocket_flightlog_1|2021-11-22 17:42:49 quantrocket.zipline: ERROR error ingesting A STK (sid FIBBG000C2V3D6), see detailed logs for traceback, continuing with next security
quantrocket_zipline_1|Ingesting 13260 minute bars for AA STK (sid FIBBG00B3T3HD3)
quantrocket_zipline_1|error ingesting AA STK (sid FIBBG00B3T3HD3)
quantrocket_zipline_1|Traceback (most recent call last):
quantrocket_zipline_1| File "sym://qrocket_qrzipline_bundles_fromdb_minute_py", line 279, in _consume_prices
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/zipline/data/resample.py", line 65, in minute_frame_to_session_frame
quantrocket_zipline_1| labels = calendar.minute_index_to_session_labels(minute_frame.index)
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/trading_calendars/trading_calendar.py", line 1053, in minute_index_to_session_labels
quantrocket_zipline_1| self._opens.values.searchsorted(index.values, side="right") - 1
quantrocket_zipline_1|TypeError: '<' not supported between instances of 'int' and 'Timestamp'
quantrocket_zipline_1|
quantrocket_flightlog_1|2021-11-22 17:43:04 quantrocket.zipline: ERROR error ingesting AA STK (sid FIBBG00B3T3HD3), see detailed logs for traceback, continuing with next security
quantrocket_zipline_1|No price data to ingest for AAAU STK (sid FIBBG00LPXX872)
quantrocket_zipline_1|Ingesting 8238 minute bars for AAA STK (sid FIBBG00X5FSP48)
quantrocket_zipline_1|error ingesting AAA STK (sid FIBBG00X5FSP48)
quantrocket_zipline_1|Traceback (most recent call last):
quantrocket_zipline_1| File "sym://qrocket_qrzipline_bundles_fromdb_minute_py", line 279, in _consume_prices
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/zipline/data/resample.py", line 65, in minute_frame_to_session_frame
quantrocket_zipline_1| labels = calendar.minute_index_to_session_labels(minute_frame.index)
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/trading_calendars/trading_calendar.py", line 1053, in minute_index_to_session_labels
quantrocket_zipline_1| self._opens.values.searchsorted(index.values, side="right") - 1
quantrocket_zipline_1|TypeError: '<' not supported between instances of 'int' and 'Timestamp'
quantrocket_zipline_1|
quantrocket_flightlog_1|2021-11-22 17:43:19 quantrocket.zipline: ERROR error ingesting AAA STK (sid FIBBG00X5FSP48), see detailed logs for traceback, continuing with next security
quantrocket_zipline_1|Ingesting 13260 minute bars for AAAU STK (sid FIBBG00QFQ8FL3)
quantrocket_zipline_1|error ingesting AAAU STK (sid FIBBG00QFQ8FL3)
quantrocket_zipline_1|Traceback (most recent call last):
quantrocket_zipline_1| File "sym://qrocket_qrzipline_bundles_fromdb_minute_py", line 279, in _consume_prices
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/zipline/data/resample.py", line 65, in minute_frame_to_session_frame
quantrocket_zipline_1| labels = calendar.minute_index_to_session_labels(minute_frame.index)
quantrocket_zipline_1| File "/opt/conda/lib/python3.8/site-packages/trading_calendars/trading_calendar.py", line 1053, in minute_index_to_session_labels
quantrocket_zipline_1| self._opens.values.searchsorted(index.values, side="right") - 1
quantrocket_zipline_1|TypeError: '<' not supported between instances of 'int' and 'Timestamp'
quantrocket_zipline_1|
As you can see, the same error happens for every security. If I restore my IBKR database from before this started happening, the ingestion is successful. This suggests that the ingestion system is intact and that the error is caused by the newly collected IBKR data. Any idea what's happening?
I'm unable to maintain a backup bundle using IBKR data while this error persists, so any thoughts would be much appreciated.