Something wrong with MQ's Product validation system?

 

Can someone please tell me why this simple piece of code wouldn't pass Product validation process? Despite it has no symbol restrictions...well nothing in fact that that should cause ' No trading operations' error.

error

//+------------------------------------------------------------------+
//|                                                ValidatorTest.mq4 |
//|                                                                  |
//|                                                                  |
//+------------------------------------------------------------------+
#property copyright ""
#property link      ""
#property version   "1.00"
#property strict

int StopLoss = 300,
    TakeProfit = 300,
    ticket=0;

double lot;

//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int OnInit()
  {
//---

//---
   return(INIT_SUCCEEDED);
  }
//+------------------------------------------------------------------+
//| Expert deinitialization function                                 |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
  {
//---

  }
//+------------------------------------------------------------------+
//| Expert tick function                                             |
//+------------------------------------------------------------------+
void OnTick()
  {
//---
   if(OrdersTotal()<1)
      SendBuy(StopLoss,TakeProfit);

  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
void SendBuy(int _stop,int _take)
  {
   if((CheckMoneyForTrade(Symbol(),OP_BUY,LotCheck())))
      ticket=OrderSend(Symbol(),OP_BUY,LotCheck(),Ask,5,Bid-_stop*Point,Ask+_take*Point,NULL,500500,0,Green);
   if(ticket<1)
     {
      Print("Order send error BUY");
      return;
     }
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
double LotCheck()
  {
   lot = MathMin(MathMax((MathRound(0.01/MarketInfo(Symbol(),MODE_LOTSTEP))*MarketInfo(Symbol(),MODE_LOTSTEP)),
                         MarketInfo(Symbol(),MODE_MINLOT)),MarketInfo(Symbol(),MODE_MAXLOT));
   return(lot);
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
bool CheckMoneyForTrade(string symb,int type,double lots)
  {
   double free_margin=AccountFreeMarginCheck(symb,type,lots);
   if(free_margin<0)
     {
      string oper=(type==OP_BUY)? "Buy":"Sell";
      Print("Not enough money for ",oper," ",lots," ",symb," Error code=",GetLastError());
      return(false);
     }
//--- checking successful
   return(true);
  }
//+------------------------------------------------------------------+
 
i'd appreciate if a moderator could look into this matter
 
Kenneth Parling:
i'd appreciate if a moderator could look into this matter

i have the same problem, for my is a bug of the page. si this link


https://www.mql5.com/en/forum/350461

Please Help
Please Help
  • 2020.09.04
  • www.mql5.com
Please Help What is the solution to this problem ?? Please help and thank you...
 
Kenneth Parling:
i'd appreciate if a moderator could look into this matter

Same problem on my side , not being able to upload new version , "no trading operations"  error, tried with older versions of the same EA and even other EA's that previously passed validation .

 

Thank you both,@Marta Gonzalez and @Catalin Zachiu.

And i'm facing the same problem as you @Catalin Zachiu,tried update older versions that previously passed without any problems and now impossible due to 'No trading operations'. The simple code and the question along with it in my thread has still not yet been answered...why!?

So i'm making my own conclusion that there would be something wrong with the automated process itself.

Perhaps someone can confirm this to be the case...?

 

There's a thread about this issue in the Russian forum you can read;

https://www.mql5.com/ru/forum/350680

Создаю тему что бы Разработчики увидели!
Создаю тему что бы Разработчики увидели!
  • 2020.09.07
  • www.mql5.com
Уважаемые разработчики, есть подозрение на ошибку валидатора маркета "no trading operations" для МТ 4 Проверка на наличие баланса для торговли...
 
Kenneth Parling:

There's a thread about this issue in the Russian forum you can read;

https://www.mql5.com/ru/forum/350680

Thanks , so there is a problem with the validator , all we can do is wait for it to get fixed , hope they fix it soon.
 

In the Russian forums ,a fellow coder reports this : (translated)

"In the new requirements, a check for the sufficiency of funds is mandatory, and if they are insufficient, the work of the advisor should be stopped. If the work does not stop the validator error, there are no trade operations ."

have you guys tried to exit completely (ExpertRemove()) in such an event ? 

https://www.mql5.com/ru/forum/350680#comment_18185450

Создаю тему что бы Разработчики увидели!
Создаю тему что бы Разработчики увидели!
  • 2020.09.07
  • www.mql5.com
Уважаемые разработчики, есть подозрение на ошибку валидатора маркета "no trading operations" для МТ 4 Проверка на наличие баланса для торговли...
 
Lorentzos Roussos:

In the Russian forums ,a fellow coder reports this : (translated)

"In the new requirements, a check for the sufficiency of funds is mandatory, and if they are insufficient, the work of the advisor should be stopped. If the work does not stop the validator error, there are no trade operations ."

have you guys tried to exit completely (ExpertRemove()) in such an event ? 

https://www.mql5.com/ru/forum/350680#comment_18185450

seems to have been tested but do not work,read about it here

https://www.mql5.com/ru/forum/350680/page2#comment_18185505

Создаю тему что бы Разработчики увидели!
Создаю тему что бы Разработчики увидели!
  • 2020.09.07
  • www.mql5.com
Уважаемые разработчики, есть подозрение на ошибку валидатора маркета "no trading operations" для МТ 4 Проверка на наличие баланса для торговли...
 

there is something wrong with automatic validation of the mql4 expert advisor when updating the product, even if I use a version that has passed the previous check it is also said  "no trading operations"


but when updating the MT5 version, it passed the test. Even though it uses logic and structures that are not that much different.


I don't think there's an update for the mql4 version and no new products to upload at this time.

 
Sugianto:

there is something wrong with automatic validation of the mql4 expert advisor when updating the product, even if I use a version that has passed the previous check it is also said  "no trading operations"


but when updating the MT5 version, it passed the test. Even though it uses logic and structures that are not that much different.


I don't think there's an update for the mql4 version and no new products to upload at this time.

There is a problem for sure yes and it's actively discusses in the Russian forum were it's also said that the administration still silent about it....well that is all i know for now

Reason: