Login Page - Create Account

Support Board


Date/Time: Mon, 03 Mar 2025 18:02:31 +0000



Trade Simulation Data Not Clearing - Pretty sure it is a bug.

View Count: 859

[2021-11-09 01:48:56]
WickedTrader - Posts: 14
Hi,

I have been running multiple bar based backtests and clearing the sim data between, but after a few tests SC seems to accumulate problems with the sim trade logs and eventually trades stop appearing in the logs and the "Clear Trade Simulation Orders and Data" no longer clears the data at all - I can execute this command multiple times and still see numerous (sim) trades in the logs.
This bug is resolved by restarting and clearing the logs again, which (after the restart) does work again.

While testing this bug for reproducibility (see attached screen recording) I found that the missing trades appeared in the logs after I restarted!

Thanks for looking into this.

Doc
Attachment Deleted.
[2021-11-09 03:43:42]
Sierra Chart Engineering - Posts: 104368
Definitely not a bug. Refer to:
Trade Activity Log: Trade Activity Not Displaying or Clearing (Improving Trade Activity Query Performance)

You are also going to want to delete, backup files of trade activity files which will be in the Backups subfolder. That folder probably has accumulated a lot of files and large files in your case.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2021-11-09 03:44:48
[2021-11-10 12:52:06]
WickedTrader - Posts: 14
Ok, thanks. As always, very helpful!
That said, I have waited for a long time previously and it still not reported expected results.
Is there any way to know that these background tasks are still in progress?
It's important to know for sure that I am looking at complete results.

You're suggesting to delete these backup files just to save space?
I have plenty of drive space, so not inclined to do this unless you're telling me this is required for some reason?
Date Time Of Last Edit: 2021-11-10 12:53:54
[2021-11-11 09:06:08]
WickedTrader - Posts: 14
Ok, so a few notes on what I have learned for anyone else with these concerns...

As per SC documentation and advice above -
"You can see the status of the completed queries in the Trade >> Trade Service Log.
And there is also an indication in the log message of how many outstanding queries there are at the time of a completed query."

Specifically, in the Trade Service logs, you can find entries saying...
e.g. "TradeActivity files query time: 0.001217 seconds. Entries: 39. Current queries: 1 | 2021-11-11 08:01:18.131"

If the last entry says "Current queries: 1"...
I think what that actually means is that it has finished! - it reports this when finishing that last query.

When doing scan based backtesting in particular, these queries accumulate and (on my system at least) can take 30 seconds or more.
Multiply that by up to 13 queries (backtesting 7 stocks in my case) and it can take a while (usually only a few minutes total though).
I'm not complaining about that, I still love SC...

I'm still not 100% convinced that there isn't an even more fundamental bug here somewhere,
...especially since checking the video of the error that I sent you...
...at no point did the Query Count in the Trade Activity Logs window say anything other than zero.
...but if I find something that remains unexplained, I will add to this thread here:

>>>
Nothing yet, probably I was wrong!
<<<

P.S. By means of feedback for SC support -
The most important thing I think I have learned is that there is a "Query Count" in the Trade Activity log.
Unless this says "Query Count: 0" the results are not complete.
You could perhaps make this more clear - making it Bold Red whenever it is not Zero perhaps.
...this would be a very sensible SAFETY measure to stop a lot of users from drawing false conclusions!
...would increase user confidence on the reproducibility of backtests (I have had my concerns and suspect this was it)!
...and would certainly save some time for your support team too!
Date Time Of Last Edit: 2021-11-11 09:29:08

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account