Algo stopped Position closed
Forums › ProRealTime English forum › General trading discussions › Algo stopped Position closed
- This topic has 45 replies, 11 voices, and was last updated 9 hours ago by
Franro.
-
-
09/06/2025 at 10:59 PM #250418
Hi,
I just received an email from IG saying a position was closed and the related algorithm stopped — on a Saturday evening…
After checking, the position was closed and the system was flagged as stopped due to an external event. What puzzles me is that the trade, which had been in a loss, was closed in profit, about 165 points above Friday’s price…
This appears to be IG-only: my IB position in the same market remained open as normal…
1 user thanked author for this post.
09/06/2025 at 11:09 PM #25042109/06/2025 at 11:35 PM #25042209/06/2025 at 11:38 PM #25042509/07/2025 at 5:37 AM #250427Same here. The BreakEven you mention looks to be in order as well (2nd SS) but in practice cannot be because of the positions being in profit or loss (I think you say the same).
The 3rd SS was taken from the little orange triangle you can see in the top-right, telling that an external event/system closed the position. Well, al least that would be correct. 🙁
I bet that this is related to the new 24/7 trading means IG started providing (since last Friday ?).
For me it seems that positions have been closed (and with that the Systems) and not the Systems without positions (also see thee 1st SS and the Pending Order in there).
Assumed this happened to all with Live positions in there, IG might be having a hard time to restore this all (probably not even possible).
What money you/we/one could claim (or return) shouldn’t be the hardest part because that is derivable from the list like your last SS and my 2nd – if needed at all (see above). Thus, look at the trade entry prices and look at the chart(s) for the exit moments and the price of that time.
I already see that the PRT detailed Reports can’t be used, because the closed trades are not in there.On second thought it feels a bit like IG had to throw out all the systems and thought : you know what ? if we close them all at break-even nobody will complain. Technically this is so (or ?). But functionally it is never what we intended.
After staring at this all for 20 minutes, it is my conclusion that my positions were in a loss of EUR 662 (screenshots with “latente winst”), which now turned into EUR 0.1 user thanked author for this post.
09/07/2025 at 6:10 AM #250431IG re-opened the position that had previously been closed…
In PRT the algorithm was stopped, so I currently have no control over that position via PRT…
I’ll need to close it manually in IG, with an unrealized loss of €339.60 at the moment…
This loss could increase due to weekend/gap risk (earliest closure is Sunday night/Monday open)…
09/07/2025 at 8:01 AM #25043209/07/2025 at 8:04 AM #250433Hmm … Nothing was reopened here ?
I’ll need to close it manually in IG, with an unrealized loss of €339.60 at the moment…
I think you could manually add a Pending Stop ? with IB that would work. It would be in effect immediately, or at least will be active at market open instantly and at the price you denoted. Or ?
… No I am not even sure. My mentioned “instantly” would be after the gap is there and the damage done.OK, what about this line of thinking :
We have had similar things in the past (not many) and when that happened, I’d let turn that trade into a Buy & Hold. For a Long position that is. This always worked out well because markets tend to rise. On a side note, for IG that would work because you can restart the same system just again, hence you would not lose the “slot” for your system. In IB that wouldn’t work (1 position per instrument allowed).
The past week I had a discussion with PRT support after I put forward my first real claim because something went bananas with IB data and a System and a trade was in a loss of EUR 1086 instantly out of my fault. The first I was “taught” in a way I didn’t feel comfortable with, was that by (their ?) law you always remain responsible for your you trading, never mind it is Autotrading. In this case this was about the gray area of the loss being there instantly (with the SL some 1000 further away) and *my* decision to leave that system be and lose more, or throw it out and take the loss. Both would be my own responsibility …
The kind of upside for my case was that the PRT platform stalled with it (choked on the wrong data ?), so I couldn’t even do something, but trying things and eventually restart PRT which helped. Then the loss was 700 or so and then I let it be. That system went out at the SL (2000) and that too was of course my own decision.
The fact that the trade should never have taken a position is what the discussion is about. The claim is quite hard to put into $. Additionally, I was coincidentally there to see it happen (at Sunday/Monday night), which is a coincidence. But, didn’t we all with IB sign that document (something like a year ago) that we must have installed automated emails, which also at night will wake you at bad occasions like this ? I did. I had to. In my case no email was sent (there was no reason to) but anyway this is their stance and this is what their (PRT first) attitude will be right from the start.
Your case, JS, is not much different. But from past events I feel that IG is more tolerant. They will know something went wrong on their side which is different from IB who is “God” to PRT – nothing can ever go wrong with IB (I tend to agree with that, but still …).09/07/2025 at 8:53 AM #250434positions in Real Live in IG are unaffected,
Coffee is working through now … above positions are all manual (not autotrading).
09/07/2025 at 9:19 AM #250435On Thursday, IG called me to warn me that there would be important updates this weekend (other updates were made last week, but no one had any problems), so I should check if the algorithms running in Live were having problems (forced shutdown), apologizing for any inconvenience… so far, no algorithm has crashed, but anyone who has problems and sees the algorithm crashed but still sees it running on their phone will have to manage the algorithm manually.
Mauro
1 user thanked author for this post.
09/07/2025 at 9:30 AM #250436Another disturbing point is that in the PRT settings I enabled the option that whenever an automated system is stopped – for whatever reason – all open positions should automatically be closed…
In practice, however, the system was stopped and I was still left with an (uncontrollable) open position…09/07/2025 at 10:04 AM #250439Jaap, that is that sentence (see SS below). This is explicit. Translated, it means that you will be able to “manipulate” the position in the IG platform itself (IB the same via TWS) and that in such a case the positions remain open.
Sadly I have to say that this change since the choice is there (your screenshot) was done in “collaboration” with me and that most I wanted to have in there, was rejected. So to be honest, it is an inconsistent whole now, although for all something can be said in Pro. But all has Cons just the same.
A lot depends on the situation, but the foremost misery is that (still) a 100 reasons exist to let them throw out your system and that most are not justified. In this very case, IMO it *is* justified, because something external indeed changed your positions (but it was not you incurring for it). In such a case your System *has* to be thrown out, but your position as well … what *was* thrown out but in your situation re-generated ? so that is the issue here, that should not have happened.Side note : By the grace of God I was able to let stay the position (to have PRT do that) when *you* killed the system yourself. Note that at the first incarnation of this change (a year back) the position was thrown out as well.
All we can do ourselves is cause these things not to happen, but this very occasion is really out of our control …09/07/2025 at 1:12 PM #250448Okayyy … So a few minutes ago this message suddenly appears (see below) and the still running system though without position, now has been thrown out as well. So the first SS I showed this morning, now got rid of its pending order (see 2nd SS below).
09/07/2025 at 1:16 PM #250451I did not read it, but for fun the Legal text attached to the email telling that the System was stopped (see attached for the link to this Legal text) :
Conditions of execution of your automatic trading systemsConditions applicable to all instruments
Start of trading systems: The first order will be placed by the system at the earliest at the open of the candlestick following the candlestick currently being formed at the time the trading system is started.
Maximum position size parameter: The parameter “Max position size” must be defined in the ProOrder window before the start of a trading system. It takes precedence over the quantities to buy/sell defined in the code of the trading system. For example, if your code had an instruction to buy 3 contracts, but you set the maximum position size to 1 contract, the order to buy 3 contracts would be ignored. Similarly, if your code had an instruction to buy 1 contract then sell short 3 contracts, the order to sell short 3 contracts would be ignored and you would remain in a buying position with 1 contract. You should always check the maximum position size parameter before starting a trading system..
Time functions: When you send a trading system to ProOrder, the time zone which was set for the market the instrument belongs to is associated to the trading system (= the time zone of your computer by default). The “intraday” time instructions used in the code of your strategy are calculated in this time zone:
- Time and similar functions (Hour, Minute)
- OpenTime and similar functions (OpenHour, OpenMinute)
- FlatAfter and FlatBefore
- IntradayBarIndex (reset to zero at the open of the market in the selected time zone)
Daily time-based instructions are always in the time zone of the market:
- DOpen, DHigh, DLow, DClose
- Date and similar functions (Year, Month, Day)
- DayOfWeek and Days
Weekend data: Weekend data is taken into account for markets that are open during the weekend.
Closed markets: If your trading system tries to place an order when the market is closed, the order will be placed when the market opens.
Insufficient capital: All of your trading systems use the same portfolio; as a result, your trading systems will use your capital with “first come, first served” logic.
Stopped trading systems:Preferences to stop trading strategies may be defined in the automatic trading preferences window (from the main window, go to “Trading” > “Preferences” > “Trading preferences” > “Automatic trading” to open it). When a system is stopped, ProOrder can:
Cancel all pending orders placed by the system and close all open positions
or
Keep trading system positions and pending orders.In case of manual modification of an order or position placed by the automatic trading system, ProOrder stops the trading system. In this case:
- Positions and orders which are attached to positions placed by the trading system will be kept, regardless of the selection in the preferences window.
- Pending orders which are not attached to positions will be kept or canceled, depending on your selected preferences.
Automatic stop of trading systems due to expiration:All running trading systems have a common validity date. If you do not click the “Extend” button before this date, ProOrder automatically stops them. You can view the validity date in the ProOrder window (expressed in your computer’s time zone) and extend your trading systems validity via the “Extend” button at the bottom of the ProOrder window when a trading system is running. The amount of time of each extension can be configured from within the “Automatic trading” tab in the “Trading preferences” window.
Automatic stop of a trading system due to number of orders placed:ProOrder may stop any given trading system as soon as the sum of pending orders on one hand and number of executed orders since 22:30 London time (23:30 Paris time) on the other hand of this system is greater than the quantity chosen in the “Automatic trading” tab of the “Trading preferences” window. Pending orders include orders that are being processed and not executed, rejected or canceled. For example, each order placed by a “SET STOP” or “SET TRAILING STOP” or “SET TARGET” instruction counts as one order as long as it has not been canceled, rejected, or executed. In addition, 3 different limit orders or 3 different stop orders that have not been canceled, rejected or executed will count as 3 pending orders. This is true if the 3 orders are on the same price level or on different price levels. If for example you choose a stopping level of 7 orders and since the market open 5 orders have been executed by a given trading system and this system has an open position and 2 pending orders (one “target” and one “stop”) and the system needs to send an additional order to the market: this 8th order will not be sent (5+2+1 reaches the stopping level).
Automatic stop of a trading system due to order rejection: If an order is rejected for one of the following reasons, ProOrder will try to place the order again, up to 10 times:
- An error occurred while processing the order
- Confirmation of order processing was not received in time
- A previously placed order on the same instrument was not yet processed by the order
For any other error (or if the order was not able to be placed after 10 tries), the trading system will be stopped, and ProOrder will try to apply your preferences when the system is stopped (keep or cancel positions and pending orders).
Multiple automatic trading systems on the same instrument:it is possible to run multiple automatic trading systems on the same instrument. In this case, your overall position on the instrument will be the sum of the positions of each trading system at a given time. For example, if 2 automatic trading systems are running on a given financial instrument, system A has a long position of 2 and system B has a short position of 1, your net position would be long 1. You should always check your net position in the “Trading” > “Portfolio” window. If multiple trading systems are running on an instrument and it is impossible to stop one of these systems due to insufficient margin, all the trading systems on that instrument will be stopped.
Customized trading hours: When a trading system is sent to the ProOrder module, any custom trading hours that were defined for the market of the instrument are associated to the trading system. These trading hours are applied to each launch of the trading system. Only data during the custom trading hours will be used to calculate indicators used by the trading system. However, stop orders and target orders may be triggered outside custom hours.
- Orders placed with instructions of type “AT MARKET”, “AT <price> LIMIT” and “AT <price> STOP” of your code will only be executed during the custom hours of the instrument.
- Orders placed with “SET TARGET”, “SET STOP” and “SET STOP TRAILING” type instructions in the code may still be executed outside the custom trading hours if the market is open.
The trading hours set when the system is started cannot be changed while it is running. If you want to change the trading hours taken into account by the system, you need to stop the system first, then change the trading hours of the instrument, then send it to ProOrder again before starting it.
1 user thanked author for this post.
09/07/2025 at 11:06 PM #250454I once again have positions opened on IG, but no positions open in ProOrder – meaning they are floating free without SL and TP. Check your positions carefully.
-
AuthorPosts
Find exclusive trading pro-tools on