I got caught up in an error that ended up spamming the server... how can I catch it?

 

Heya team,

I got this error today and I don't have anything to catch random breaks like this that I'm not foreseeing. The EA ended up spamming the server this way an unmentionable amount of times.  How do I write some catch code for odd errors like this? Maybe something like "If error count exceeds 100 tries of any nature, abort and report." I think something like this happened when set stop loss took out a position mid function, otherwise, im not sure what happened. But once i restarted the app, the error stopped. Thanks for your help!

Error:

unknown ticket 55380534 for OrderDelete function

Breakeven signal: cancel pending order 55380534
 
Robert Victor Huizar: I got this error today and I don't have anything to catch random breaks like this that I'm not foreseeing. The EA ended up spamming the server this way an unmentionable amount of times.  How do I write some catch code for odd errors like this? Maybe something like "If error count exceeds 100 tries of any nature, abort and report." I think something like this happened when set stop loss took out a position mid function, otherwise, im not sure what happened. But once i restarted the app, the error stopped.

You catch it by properly checking your functions' return values in your program code, and when it fails, checking the error codes (or trade return codes) and reacting accordingly,

Yes, I know it sounds vague and unsubstantiated, but then, so is your question.

 
Fernando Carreiro #:

You catch it by properly checking your functions' return values in your program code, and when it fails, checking the error codes (or trade return codes) and reacting accordingly,

Yes, I know it sounds vague and unsubstantiated, but then, so is your question.

Thanks for helping me out last time, and I appreciate your help this time too.  Unfortunately, this error that was created by an EA that was purchased in the market so I don't have access to the code, which is why I was wondering if there was a way to catch general errors.  I didn't see the error in the expert log nor the journal (I only found it by seeing an exceptionally large log file looking for other data).  I guess to be more specific, how do I catch a large number of errors that I'm not directly responsible for and have no feed alert for? Maybe an EA that can parse a log for an abnormal number of errors and shut it down? not sure if this is possible...

Thank you!

 
Robert Victor Huizar #: Thanks for helping me out last time, and I appreciate your help this time too.  Unfortunately, this error that was created by an EA that was purchased in the market so I don't have access to the code, which is why I was wondering if there was a way to catch general errors.  I didn't see the error in the expert log nor the journal (I only found it by seeing an exceptionally large log file looking for other data).  I guess to be more specific, how do I catch a large number of errors that I'm not directly responsible for and have no feed alert for? Maybe an EA that can parse a log for an abnormal number of errors and shut it down? not sure if this is possible...

Thank you!

Theoretically you can probably write an external program that monitors the logs and alerts you, but it would need to be a very sophisticated and is not really a feasible solution.

Instead,contact the author and request that the issue be fixed. If they fail to do so, then they will be in violation of the Market rules and you can report them them to the Service Desk.

There is no other way to fix the error.