What the logbook entry means - page 5

 
Несколько смущает тот факт, что на 37 постов этой ветки приходится только один от разработчиков...

why interfere in an already productive discussion


The developers don't want to scare us off in case we find something interesting for them... :)
 
Несколько смущает тот факт, что на 37 постов этой ветки приходится только один от разработчиков...

why interfere in an already productive discussion


For the following reasons:
1. To say, guys, we acknowledge (or not) that there is a problem and we will treat it.
2. To say, Quark (and Composter, since he reproduced the error on his EA), we looked at your code, the error is in it, treat so-and-so.

Otherwise it turns out you are not interested. Have fun, kids...

I will repeat my arguments:
1. Orders to open and close positions sometimes return errors.
2. These error codes have nothing to do with real life (e.g. "wrong price", even though the price is correct).
3. By repeating the attempt with the same parameters you can make the system accept the order. But nowhere in your manual does it say that the same order must be opened (closed) in a loop with error checking at each step and output to a file for later manual checking.
4. Sometimes error codes are not returned, i.e. the program behaves as if the operation was successful. But it fails.

5. Most importantly. Since the problem occurs when communicating with the demo server (Alpari, in my case), it is very likely that having found a workaround now, on the demo, we will find ourselves in the same situation again when we go to the real one. And then we will have to pay for debugging again. With your own money.

6. This is NOT a local problem of one expert. I argue that all, or at least many EAs, may simply not catch it, as there is no error catching system attached to my EAs. Hence, it follows that optimization can NOT be transferred to real, because orders will not be opened and closed in the same way and not always. It follows that people will be wasting time and money.

7. I don't really believe this is an EA problem. Point out where it is, if I am wrong. You can change the expert's logic, it's not about logic.

Here.
 
Quark, we ran your EA on a test machine with a terminal connected to alpari. we put it on 11 different pent ups. we are ready to wait for the result until the end. as soon as the described situation arises, we will press the debug button. so, no response does not mean a lack of attention. i repeat, we read ALL posts on our forum and analyze ALL posts. and we are not email robots that stupidly respond with a "your message has been read and noted". sorry.
 
About the trade context - if you look at the EA code, it first waits nMagic * 10 seconds, which guarantees it an exclusive 10 seconds, then sets the global semaphore (which guarantees that other EAs will be hung). And only then does he trade.

Roche, here are the logs for today, with an in-cycle delay after OrderSend and OrderClose of 10000ms. It seems to remove suspicions of a conflict due to timing and context (which shouldn't be there anyway):

Attempting to close short position, ticket: 1827283
9.9.2005 10:13:20 Order with this ticket still present, trying again
9.9.2005 10:13:48 No more orders with this ticket No

On second try :(

9.9.2005 0:14:54 Trying to buy, attempt 0
Bid: 1.24490000, StopLoss: 0.00700000, TakeProfit: 0.00000000 failed, error 6
9.9.2005 0:15:4 Trying to buy, attempt 1
Bid: 1.24470000, StopLoss: 0.00700000, TakeProfit: 0.00000000 successfull

On second try :(

9.9.2005 13:0:22 Trying to buy, attempt 0
Bid: 1.23900000, StopLoss: 0.00600000, TakeProfit: 0.00000000 failed, error 6
9.9.2005 13:0:48 Trying to buy, attempt 1
Bid: 1.23900000, StopLoss: 0.00600000, TakeProfit: 0.00000000 successfull

On second try :(

Pause failed...
Please note, that error 6 (the most informative one in the world) appeared only at buying, at closing there was no error. True, there was a ping error in the log, but the expert doesn't know about it...
 
Quark, we ran your EA on a test machine with a terminal connected to alpari. we put it on 11 different pent ups. we are ready to wait for the result until the end. as soon as the described situation arises, we will press the debug button. I repeat, we read ALL of the messages on our forum, and we analyze ALL of them.


They say if a person is talking to God, that's fine. But if God starts answering, that's a problem :) But I'm glad anyway :)

Just a reminder that the Expert Advisor will not trade on 5-minute trades by default. There's a clock coded in there, you have to change it.
Also I have no idea how easy it is to catch this on 5 minutes. Also :) if testing as you described, cycles should be disallowed as they are designed to dampen the error. There will of course be an entry in the logs, but it may be too late to push the button.

Finally, I guess, we can add the same logic (call of my functions instead of OrderSend and OrderClose) to other EAs. For the sake of consistency. I think I'll be able to catch something too.

Good luck,
Quark
 
Quark, we ran your EA on a test machine with a terminal connected to alpari. we put it on 11 different pent ups. we are ready to wait for the result until the end. as soon as the described situation arises, we will press the debug button. so, no response does not mean no attention at all. I repeat, we read ALL posts on our forum and analyze ALL messages. and we are not mail robots that stupid answer "your message has been read and noted". sorry. i'
ll probably send you the code too - besides this bug, my istradeallowed won't work...
 
I'll probably send you the code too - in addition to this bug, my istradeallowed also prevents it from working...

send it to me. that's what we're catching
 
I mentioned earlier that I didn't set out to catch problems with pending orders. But I have a simple troubleshooter :) and it did catch one of them (error 6). I am pasting the code below.

I would like to emphasize that this code does not depend on any conditions, except for triggering of the second of two pending orders. Therefore, this code was called again an hour later (I was out of my home) and the pending order was deleted. The alert message persisted.

So, the system worked this time, without restarting the terminal. I do not exclude that other cases (with urgent orders) also result from temporary terminal shutdown.

This agrees with the fact that repeating the operation request in the loop, you may succeed at the second, third and so on.

	if(nNumOfOpenedOrders > 0) { for(nCnt = OrdersTotal() - 1; nCnt >= 0; nCnt--) { OrderSelect(nCnt, SELECT_BY_POS, MODE_TRADES); if(OrderMagicNumber() == nMagic && 
				(OrderType() == OP_BUYSTOP || OrderType() == OP_SELLSTOP)) { bool bResult = OrderDelete(OrderTicket()); if(bResult == false) { int nError = GetLastError(); Alert("SimpleBreak " + Symbol() + " error: " + nError); } } }
 
Quark, a miracle has happened =)
Your expert has opened a position =)))

All 8 have been hovering on the watch for a long time and no one is trading... And now at 15:00 on Alpari a position opened. Is this normal?)
 
Quark, a miracle has happened =)<br/ translate="no"> Your expert has opened a position =)))

All 8 have been hovering on the watch for a long time and no one is trading... And then at 3pm Alpari opened a position. Is this normal?)


It opened for me too, and at 15 :)
The previous position, also successfully, was opened on USDCAD 23.08.

Actually, it is a good Expert Advisor, and it does not fail most of the time. So does any other one. Judging by the logs, it is not the trading logic but the fact. Therefore, you can rewrite the Expert Advisor, for example, to reverse positions every hour - it will generate more trades :) And there will be more failures too.
This EA is just an example to give to developers. Otherwise they all fail from time to time. And you, too, as I understand it, so it's not because of our code...
Reason: