what's up with these prices errors ?

 

It's not the first time it happens. Wrong price is used instead of the right one, resulting in an enormous loss in the backtest


I don't think my code is wrong, because error comes and goes.


BTW it's an OPEN PRICE backtest


I restart MT5 and error is gone

Files:
 
Jean Francois Le Bas: I don't think my code is wrong

How To Ask Questions The Smart Way. (2004)
          Don't rush to claim that you have found a bug.
Questions Not To Ask
          My program doesn't work. I think system facility X is broken.

It is almost always your code.

 

so please tell me how do I close a trade on EURGBP at price 1.23181 when the actual price is around 0.86 then i'll consider your input

 

This topic is a waste of time if you don't provide the technical details and code to reproduce the issue.

I have a multisymbols EA which run without any problem with the Strategy Tester (using 1 Minute OHLC or real ticks, Open prices isn't suitable in my case).

 
Alain Verleyen #:

This topic is a waste of time if you don't provide the technical details and code to reproduce the issue.

I have a multisymbols EA which run without any problem with the Strategy Tester (using 1 Minute OHLC or real ticks, Open prices isn't suitable in my case).

i'm also a programmer so I understand the "please give us a way to reproduce the error" thing, but it happens from time to time that's the problem : and I restart MT5 and it's gone

I wish I could give you better examples but I cannot

sorry

i'm willing to believe it's my code, but I don't understand how it can close an order at a price so wrong

I don't think it's possible hence I think it is a bug
 

I had two other times it happened today (only screenshoted once).

Files:
 
another one.
Files:
 
+
Files:
 
Jean Francois Le Bas #:

i'm also a programmer so I understand the "please give us a way to reproduce the error" thing, but it happens from time to time that's the problem : and I restart MT5 and it's gone

I wish I could give you better examples but I cannot

sorry

i'm willing to believe it's my code, but I don't understand how it can close an order at a price so wrong

I don't think it's possible hence I think it is a bug
Restarting is not a solution, it's a workaround. The origin of the problem can be an MT5 bug, a bug in your code or something external to these 2 things. The only way to know it for sure is to investigate by reproducing the problem. Everything else is guessing and waste of time. And for sure talking about probabilities, the most probable is a bug on your side.
 
Jean Francois Le Bas #:
+
In your screenshots it looks like metatrader is loading the same history for the multiple symbols(using GBPUSD's history for EURGBP).
Could it be an antivirus messing with the tester's cache?
Does this happen on other machines?
Another issue that I could think of is dying SSD, at one point they stop writing to specific sectors but will read the old data there.
 
Alexandre Borela #:
In your screenshots it looks like metatrader is loading the same history for the multiple symbols(using GBPUSD's history for EURGBP).
Could it be an antivirus messing with the tester's cache?
Does this happen on other machines?
Another issue that I could think of is dying SSD, at one point they stop writing to specific sectors but will read the old data there.

thanks for both your inputs


my S.M.A.R.T thresholds are ok :)


I tried without restarting, and I got different results now, so two successive backtests give two different results. that's very strange

the problem is to reproduce the error, without it it becomes very hard to pinpoint it

i'll check my code

Reason: