I have continuously received the following error when attempting to backtest and do not know how to resolve it:
Error Message
[ERROR] FATAL UNHANDLED EXCEPTION:Engine.Run(): Error running algorithm System.ArgumentException: Unable to locate next market open within two weeks., at QuantConnect.Securities.SecurityExchangeHours.GetNextMarketOpen(DateTime localDateTime, Boolean extendedMarketHours) in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Common/Securities/SecurityExchangeHours.cs:line 320, at QuantConnect.Scheduling.TimeRules.<>c__DisplayClass14_0.b__1(DateTime date) in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Common/Scheduling/TimeRules.cs:line 172, at System.Linq.Enumerable.SelectEnumerableIterator2.MoveNext(), at QuantConnect.Scheduling.ScheduledEvent.get_NextEventUtcTime() in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Common/Scheduling/ScheduledEvent.cs:line 80, at QuantConnect.Lean.Engine.RealTime.BacktestingRealTimeHandler.<>c.b__11_0(KeyValuePair2.ComputeKeys(TElement[] elements, Int32 count), at System.Linq.EnumerableSorter1.Sort(TElement[] elements, Int32 count), at System.Linq.OrderedEnumerable2.ToList(), at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source), at QuantConnect.Lean.Engine.RealTime.BacktestingRealTimeHandler.GetScheduledEventsSortedByTime() in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Engine/RealTime/BacktestingRealTimeHandler.cs:line 156, at QuantConnect.Lean.Engine.RealTime.BacktestingRealTimeHandler.Setup(IAlgorithm algorithm, AlgorithmNodePacket job, IResultHandler resultHandler, IApi api, IIsolatorLimitResultProvider isolatorLimitProvider) in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Engine/RealTime/BacktestingRealTimeHandler.cs:line 52, at QuantConnect.Lean.Engine.Engine.Run(AlgorithmNodePacket job, AlgorithmManager manager, String assemblyPath, WorkerThread workerThread) in /LeanCloud/CI.Builder/bin/Debug/src/QuantConnect/LeanEnterprise/Engine/Engine.cs:line 295
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!