MT5 Build 6328 — Scripts load but OnStart never executes; initialization fails after approximately 300 seconds
Environment: - MetaTrader 5 terminal build 6328 - Windows 10 build 19045 - A minimal MQL5 script compiles successfully (0 errors, 0 warnings). - Script uses int OnStart(), with Print() as its first statement. No trading, DLL, file I/O, or terminal-control calls. Observed behavior: - In an isolated portable terminal session, three separate scripts were reported as loaded, then later logged "failed initialization" (return code 0) and were removed. - The three load-to-failure intervals were approximately 300 seconds. - The first Print() from the minimal diagnostic script did not appear in the terminal journal. - The same minimal marker pattern succeeded in a separate test terminal under a different connection state. This is a control observation only; it does not establish connection state as the cause. - The terminal journal contains inherited lines from an earlier terminal session; only entries identified as belonging to the current session were used. Questions: 1. What internal conditions can cause a script to be reported as loaded but never receive/execute its Start event? 2. Can a script initialization watchdog or timeout produce a failure at approximately 300 seconds? 3. Is there a known issue in build 6328 involving script event dispatch or initialization? 4. Which terminal logs or diagnostic flags can identify the failing subsystem? 5. Does an isolated portable terminal with no broker login have any restrictions affecting script Start-event dispatch? 6. What is the recommended safe diagnostic procedure to isolate the cause without changing account or trading state? We are not claiming a confirmed root cause. We can provide redacted logs and minimal source/hash details to MetaQuotes privately if requested.
- New MetaTrader 5 Platform Build 6230: Expanded AI Capabilities
- MT5 Build 6230 Minimal MQL5 Script fails initialization before OnStart (error code 0)
- MetaTrader 5 build 6230 + Python API 5.0.6231 -10005 IPC timeout
J22 Channel:
The three load-to-failure intervals were approximately 300 seconds.
The three load-to-failure intervals were approximately 300 seconds.
300 seconds is 5 minutes. Do you actually mean 3000 milliseconds? 3000 milliseconds would likely indicate that the _StopFlag was triggered.
You can post your code for others to troubleshoot, or you can prompt the MT5 AI Assistant to troubleshoot your code in your specific MT5 Build.