Hi everyone, my code has a lot of stocks in its universe, probably 6000 or more, and in OnSecuritiesChanged, I have a history call that looks back 50 data points at Resolution.Minute. 

I understand that universe selection runs between 4 am to 7 am in live trading, and I understand that currently there is no way to schedule universe selection for live trading, and also, that history calls take a relatively large chunk of time, especially in my case because I'm making a history call for 6000 stocks. 

So here's my question, what happens when my algorithm is running its logic between 4 am to 7 am and universe selection happens at the same time? For example, if logic is running between 4 - 4.30 am, and universe selection happens at 4.30 am, will it just stop running its logic? What if new data is being pumped in to OnData while it is running universe selection? 

Author

Cheng Li

July 2021