Ok, fair enough, long lookback was just an example which is relevant to something I've been working on.
I actually don't even need long lookback but I need to scan & gather data points from a few years back so I force Zorro scanning history with a long LOOKBACK period...
Any suggestions? Perhaps a new flag imitates LOOKBACK run but without making LOOKBACK any longer?

However, I still think there can be other cases which may suffer from current PRELOAD design.
Here's another example with short lookback (100) and weekly bars.
History was downloaded from broker without PRELOAD flag. It is actually more than 1 year, contrasting what manual suggests (max 1 year).
LOOKBACK is fulfilled and run() function worked as expected.
I trimmed the logs to make them shorter but you'll get the point.

Code
void run()
{
	set(LOGFILE, TICKS);
	Verbose 	   = 3;
	
	History 	   = "*.t6";
	BarPeriod 	   = 10080; // Weekly bars
	LookBack 	   = 100;
	LookBackResolution = 60; // Speed up download from broker
	
	printf("Time: %s \n", strdate("%d %b %y", wdate(0)));
}

Log:
Quote
testlb2
Login 0 Oanda V20..
!account 101-004-9964544-004 at UTC 01-11 22:46Time: 11 Jan 24

V 2.600 on Fri 24-01-12 01:46:37 (Zorro S Subscription)
Load AssetsFix
Warning 054: EUR/USD LotAmount 1000 -> 1.0
Warning 054: EUR/USD PIPCost 0.1000 -> 0.0001000
!EUR/USD 08-31 22:46:39 to 01-11 22:46:39
!=> 12-22 12:00:00 to 01-11 23:00:00, 300 ticks
Load EUR/USD prices..
!EUR/USD 08-31 22:46:39 to 12-22 11:30:00
!=> 12-06 01:00:00 to 12-22 12:00:00, 300 ticks 20944 h, 8624 bars added
EUR/USD 29568 ticks read
Warning 014: bar 67 gap at UTC 2021-01-01 15:40:00
226(29620) bars 2019-09-13..2024-01-12 generated
EUR/USD: 0..29619

Trade: testlb2 EUR/USD 2024-01-11
Loading Data\testlb2_d.trd (V2.600)
Lookback 100 bars, 2022-02-18..2024-01-12

[126: Fri 22-02-18 15:40] 1.13895/1.14090\1.12811/1.13490 -0.00020Time: 18 Feb 22
.
[127: Fri 22-02-25 15:40] 1.13490/1.13922\1.11072/1.12335 -0.00020Time: 25 Feb 22
[128: Fri 22-03-04 15:40] 1.12334/1.12762\1.08867/1.09096 -0.00020Time: 04 Mar 22
[129: Fri 22-03-11 15:40] 1.09097/1.11224\1.08068/1.09826 -0.00020Time: 11 Mar 22
...
...
...
...
[221: Fri 23-12-15 15:40] 1.07471/1.10101\1.07409/1.09203 -0.00020Time: 15 Dec 23
[222: Fri 23-12-22 15:40] 1.09207/1.10410\1.08893/1.10369 -0.00020Time: 22 Dec 23
[223: Fri 23-12-29 15:40] 1.10369/1.11404\1.10009/1.10695 -0.00020Time: 29 Dec 23
[224: Fri 24-01-05 15:40] 1.10702/1.10794\1.08777/1.09506 -0.00020Time: 05 Jan 24

Bar 225 continued until 15:40:00 Fri

End of lookback period at 22:47:13 Thu


Below is the same code with PRELOAD flag.
It throws Error 047 because 2022 history isn't loaded...
Code
void run()
{
	set(LOGFILE, TICKS, PRELOAD);
	Verbose 	   = 3;
	
	History 	   = "*.t6";
	BarPeriod 	   = 10080; // Weekly bars
	LookBack 	   = 100;
	LookBackResolution = 60; // Speed up download from broker
	
	printf("Time: %s \n", strdate("%d %b %y", wdate(0)));
}

Log:
Quote
testlb2
Login 0 Oanda V20..
!account 101-004-9964544-004 at UTC 01-11 22:48Time: 11 Jan 24

V 2.600 on Fri 24-01-12 01:48:49 (Zorro S Subscription)
Load AssetsFix
Warning 054: EUR/USD LotAmount 1000 -> 1.0
Warning 054: EUR/USD PIPCost 0.1000 -> 0.0001000.
EUR/USD 385045 ticks read
53(342) bars 2023-01-13..2024-01-12 generated
Error 047: EUR/USD 2023-01-13 2024-01-11: 53 bars, 6819 skipped, 100 needed)
EUR/USD: 0..341

Trade: testlb2 EUR/USD 2024-01-11
Loading Data\testlb2_d.trd (V2.600)
Lookback 100 bars, 2023-01-20..(NaD)

[1: Fri 23-01-20 15:40] 1.08266/1.08877\1.07664/1.08373 -0.00019Time: 20 Jan 23
.
[2: Fri 23-01-27 15:40] 1.08373/1.09298\1.08226/1.08583 -0.00019Time: 27 Jan 23
[3: Fri 23-02-03 15:40] 1.08582/1.10336\1.08024/1.08675 -0.00019Time: 03 Feb 23
[4: Fri 23-02-10 15:40] 1.08673/1.08766\1.06693/1.06976 -0.00019Time: 10 Feb 23
...
...
...
...
[48: Fri 23-12-15 15:40] 1.07733/1.10093\1.07404/1.09123 -0.00019Time: 15 Dec 23
[49: Fri 23-12-22 15:40] 1.09122/1.10403\1.08886/1.10232 -0.00019Time: 22 Dec 23
[50: Fri 23-12-29 15:40] 1.10231/1.11397\1.09946/1.10751 -0.00019Time: 29 Dec 23
[51: Fri 24-01-05 15:40] 1.10750/1.10782\1.08771/1.09881 -0.00019Time: 05 Jan 24

Bar 52 continued until 15:40:00 Fri

End of lookback period at 22:48:52 Thu