How to deal with "log files size exceeded 20xx MB, test terminated" while publishing?

 

I have isLogging parameter in EA to indicate whether calling Print() or not. 
I turned it off but failed to pass validation of MQL5. 
Then I removed this parameter, I can pass the validation. 
But I want to log something instead of turn it off. 
May someone advise how to fix it wisely? e.g. can I clean up testing log while running Back Test, etc?

 
Hardworking Pig:

I have isLogging parameter in EA to indicate whether calling Print() or not. 
I turned it off but failed to pass validation of MQL5. 
Then I removed this parameter, I can pass the validation. 
But I want to log something instead of turn it off. 
May someone advise how to fix it wisely? e.g. can I clean up testing log while running Back Test, etc?

use this : 

       

         if(!MQLInfoInteger(MQL_TESTER) || MQLInfoInteger(MQL_VISUAL_MODE))
            Print("some logs");
 
Hardworking Pig:

I have isLogging parameter in EA to indicate whether calling Print() or not. 
I turned it off but failed to pass validation of MQL5. 
Then I removed this parameter, I can pass the validation. 
But I want to log something instead of turn it off. 
May someone advise how to fix it wisely? e.g. can I clean up testing log while running Back Test, etc?

Set the default behaviour to "off", meaning that by default the printing to the logs is disabled. The user can then enable it when they want.
Reason: