
THE QUESTION
A classic intraday backtest bug: a daily high or low read with request.security(), lookahead on and no one-bar offset, so each historical bar knows its day’s final high and low. The usual fear is a backtest that looks too good. Does it?
WHAT I MEASURED
The open-source strategy “Liquidity Sweep, MSS and FVG Entry Model with Look-ahead A/B” on this MNQ1! 15m chart, default inputs, Strategy Tester default range (first trade 1 Dec 2025, last 20 Oct 2026), run twice: as published and with its look-ahead demo on.
WHAT THE TABLE SHOWS
Honest build: Sweep 336, MSS 100, FVG 83, Fill 62, so 274 sweeps never became a trade. Demo: 300, 85, 68, 50. Tester, honest: 62 trades, 54.8% winners, profit factor 0.963, net -196.50 USD. Demo: 50 trades, 54.0%, 0.779, -1,224.50 USD.
READING
With the leak, the day pool is a price no bar of that day trades beyond: when it is the nearest pool it is never swept, and on the other side it can become the profit target. Matched by entry, the demo kept 45 of the 62 honest entries (3 exited elsewhere), dropped 17 and added 5. Look-ahead does not always flatter a backtest; here it made it look worse, and a result built on it says nothing either way.
LIMITS
Both runs lost money: neither shows an edge. One symbol, one timeframe; 100,000 capital, 1 contract, 2.25 commission per contract per side, 1 tick of slippage.
TRY IT
The code is open and the switch is in the inputs: flip it on your chart and compare. Not financial advice.
