Multiple deals opening at the same time

Bug info: Bot is set up in a way that opens deals when BOTH higher timeframe condition and lower timeframe condition are met.

  • Higher timeframe: 4 hour technical indicator
  • Lower timeframe: 30 min technical indicator

Expected behavior is that when higher timeframe indicator is TRUE, there will be 1 deal openned every time that the lower timeframe indicator turns TRUE. So that is at most 1 open opened every 30 minutes.

Actual behavior: 3-4 deals openned at the same time.

Sample Deal IDs of the same trading pair of the same bot, 3 deals opening within the same 30-min timeframe.
6769cca072b766aa5ba2ffd3. opened at 04:48:32
6769ce3f72b766aa5ba442ef. opened at 04:55:27
6769ccd772b766aa5ba32ef4. opened at 04:49:27

  • Bot URL → Gainium app
  • [Optional] Steps to reproduce →
  • Expected result →

Did those open in parallel or one by one? If you allowed more than one deal per pair, why shouldn’t the bot open as many deals as you allowed it when the lower timeframe indicator became true as well.

Ok my understanding is that the deal will open each time that the lower time frame indicator is true.

For example, if higher timeframe 4-hour indicator is true, then at most there will be 8 deals open for the 30-min indicator if it is true throughout this period. I would expect 1 deal opened per 30 minute.
So for example:
While 4H indicator is true

  • if 1st 30min (00:00 - 00:30) indicator is true, open 1 deal
  • if 2nd 30min (00:30 - 01:00) indicator is true, open 1 deal
  • if 3rd 30min (01:00 - 01:30) indicator is true, open 1 deal

However in the quoted example there are 3 deals opened within 10 minutes, not sure what decided that 3 deals are opened within such a short timeframe.

I can’t see your configuration or deals. Did you allow multiple deals per pair? Were the first deals closed when the other started? Did you use cooldown after start?

ok the bot has the following configuration:
Deal start:
4H indicator is true AND 30-min indicator is true
Yes allowed multiple deals per pair
The first deal did not close when the others started
No cooldown used

My concern is that there should be 1 deal opened every 30-min (when both 4H and 30min indicators are true), but if there are multiple deals opened in the same 30-min window, then what determines deal start trigger?

Apparently that both conditions are true and that there are free slots to open another deal. If cooldown would work per pair you could use that to prevent another deal for the same pair on the same triggers. Otherwise you would also block other deals of pairs with matching conditions.

It was due to deal merge, it triggered reprocessing of the candle. It has been fixed.

2 Likes

That is, if all conditions are met then it was meant to trigger only once per pair and we don’t require a cooldown for it?

Thanks for clarifying. For now as a safety guard i just configure cool time period of 29min per symbol for the 30-min low timeframe indicator trigger.

Only make sure that it doesn’t prevent other deals from starting if you use a multi pair bot with more than one pair. I currently don’t know whether cool down works per pair.

Yes there is option to select whether the cooldown is applicable per bot or per symbol

1 Like