MetaTrader5 Python initialize() returns -10005 IPC timeout on MT5 build 6230
Hello,
I am trying to connect Python to the already running MetaTrader 5 terminal for read-only diagnostics. No orders have been sent.
Environment:
- Windows 64-bit
- Python 3.13.3, 64-bit
- MetaTrader5 Python package 5.0.6231
- MetaTrader 5 terminal build 6230
- Standard, non-portable terminal installation
- Terminal path: C:\Program Files\MetaTrader 5\terminal64.exe
- The terminal is connected to a MetaQuotes-Demo account
The terminal and the PowerShell session running Python are started by the same Windows user, in the same session, and neither is elevated.
The minimal call is:
mt5.initialize(path=r"C:\Program Files\MetaTrader 5\terminal64.exe")
Result:
initialize: False
mt5.last_error(): (-10005, "IPC timeout")
I have seen a MetaQuotes moderator report that build 6230 with package 5.0.6231 initializes successfully on their setup, so I understand this may not be reproducible everywhere. I would like to find what differs in my environment.
Could you advise which additional diagnostics would help identify why the IPC handshake times out? I can provide the terminal Journal and log lines around the time of the error, with the account number redacted.
Thank you.
Documentation on MQL5: Account Properties / Constants, Enumerations and Structures
- www.mql5.com
To obtain information about the current account there are several functions: AccountInfoInteger() , AccountInfoDouble() and AccountInfoString() ...
- Persistent mt5.initialize() IPC Timeout (-10005) on MT5 Build 6231 with Python 3.13 (64-bit)
- MetaTrader 5 build 6230 + Python API 5.0.6231 -10005 IPC timeout
- MetaTrader5 Python initialize() returns -10005 in account-free offline tests on Windows and Wine