Why my EA now refuses to trade the first bar after a reconnect
Posted: Fri Oct 30, 2026 4:34 pm
Small change to my EURUSD EA that saved me a few silly trades: after any reconnect to the trade server, the EA waits for one full M1 bar to close before it's allowed to open anything.
Why I added it:
Since adding it in late August there have been 14 reconnects logged and no trade opened in the blocked window. Obviously I can't prove the trades I skipped would have lost, but the ones before were clearly junk.
Does anyone handle reconnects differently, for example with a fixed number of seconds instead of a bar?
Why I added it:
- After a reconnect the terminal sometimes backfills a few missed ticks at once. My indicators recalculated on the jump and produced a signal that was never valid in real time.
- Spreads right after a reconnect on my VPS were sometimes the stale ones from before the drop, so the spread filter passed when it shouldn't have.
- Two of my worst trades in August opened within 5 seconds of a reconnect.
Since adding it in late August there have been 14 reconnects logged and no trade opened in the blocked window. Obviously I can't prove the trades I skipped would have lost, but the ones before were clearly junk.
Does anyone handle reconnects differently, for example with a fixed number of seconds instead of a bar?