To reproduce what I am seeing:
- Import MyCustomTest strategy.
- Open StrategyAnalyzer, and set as per the attached screenshot.
- Open Output Window.
- Open MyCustomTest strategy in NinjaScript Editor, and re-compile.
- Run optimization.
- “Should_never-appear” appears twice in Output Window!
The strategy has IsInstantiatedOnEachOptimizationIteration set to false. The strategy is set up to place a long entry order on the 101st bar, and then print something to the Output Window in OnExecutionUpdate() if a certain condition is satisfied.
By my understanding “Should_never_appear” should not appear in the Output Window in this optimization; it should only be printed if Enums has the value Should_never_appear... but Enums was set to Set_to_this for the optimization.
Why does the output window show Should_never_appear?
Comment