Hey,

I'm looking to create a simple futures strategy that looks at the past (for example) 5 days of data, and uses these 5 Daily TradeBars to determine an entry. One example might be mean reverting - if 5 closes are consecutive highs, then go short, and if consecutive lows, go long. I digress, the problem I'm having is that Futures do not support the Daily data resolution, so I was using a Consolidator to consolidate Minute data into Daily data. I have this working well with my Futures template algo that handles Rollover, but the Consolidator breaks after the 1st rollover. Per the Logs in my attached Backtest (for whatever reason the Backtest dropdown is not showing my latest backtests after refreshing the page etc, will try to attach in the comments):

2019-03-14 14:16:00 : Runtime Error: Consolidators can only be used with a single symbol. The previous consolidated SecurityIdentifier (ES X2U8QNK1AEIP) is not the same as in the current data (ES X5IQJTEKSC8X).

You can see in the logs before this occurs, I remove the subscription, though it seems like multiple concurrent subscriptions is not the error it's concerned about:

2019-03-14 14:15:00 : Subscription REMOVED from consolidator _dailyConsolidator for contract ES15H19 2019-03-14 14:15:00 : list of sorted recent contracts: ES21M19, ES20U19 2019-03-14 14:15:00 : New active contract set to ES21M19 2019-03-14 14:15:00 : Subscription ADDED for consolidator _dailyConsolidator for contract ES21M19 2019-03-14 14:15:00 : Portfolio liquidated. 2019-03-14 14:15:00 : New contract purchased: ES21M19 2019-03-14 14:15:00 : Contract ES21M19 has will have rollover triggered on: 6/20/2019

I looked through the QC forums and found some posts (post 1) (post 2) that rougly discuss futures, consolidators, and rollover, but do not address my problem of using a consolidator for multiple futures contracts as they are rolled over.

 

Any tips on how I can get Daily data from rolled over futures contracts? Is there a way I can get the QC Consolidator to work for multiple futures contracts in a single backtest, perhaps by some crafty abstraction of the OnDay() event handler?