All looks into the past must be <= LookBack at any time, because that is the very purpose of the LookBack variable.

Sure, you're right that in the backtest it would not matter because you have access to the whole price curve. But I suppose you'd run into a problem when you tried to trade that live.