Workflow Duplication

Hi Everyone,

I am having a issue that just started recently. Pretty much i have a application that triggers a workflow. For some reason just recently sometimes it duplicates the run and runs again. This is only sometimes and other times it works. I am not sure if it is something in the app as it has been fine for the past few months and just started this issue.

Hi @Trey_Anderson, can you share some more info on how your application triggers the workflow? That could help us narrow down the issue.

Also, I'd be happy to investigate further if you send me a workflow run ID for one of your duplicated runs. A screenshot of what you're seeing on the client side may be helpful as well. Thanks!

Hi @Mike_M, the workflow is being triggered inside a application via a button but once the button is pressed it only allows it to be pressed once. Here is the most recent duplication, dbe79b1e-c82b-4680-af4e-040d0b33e1b6

I looked deeper into this, and found some logs that seem to match the times of those requests, but I'm not seeing any obvious indicators that these are being duplicated on our end. I am curious about a few things:

  1. Is it possible that these are being triggered by two different users at the same time?
  2. Is the application open in more than one tab when this happens?
  3. Would it be possible to share a screenshot of the application logs when this happens? That way we could see if a workflow is triggered more than once from the application.
  4. Lastly, screenshots of the duplicated workflow logs would be helpful as well. It should look something like this:



The top screenshot is for the top and the bottom for the bottom. It is hard to get the logs because it is being sporadic and I do not believe that 2 users would be submitting the same info at the same time or having multiple tabs open, I will check on that.

Thanks for sharing the screenshots! The fact that they are both triggered from the Retool app has me leaning towards this being something on the application side rather than workflows.

What logic is in place to make sure the button is only pressed once?

Once the button is pressed it hides that page and shows a page to indicate things are running so it should immediately hide

How is the page hidden? I tested out a button that uses utils.openPage() and console.log when it's pressed, and I was able to double click in the time it takes to change pages. Another way to further ensure a button can't be clicked twice would be to add a buttonName.setDisabled(true) when it's clicked.

Not to say that that's for sure whats happening, but I could imagine it is something like that since it's infrequent.

Hmm maybe they could be just weird that this kind of just started in the last month or so. Ill add that to the button to make sure that it is not being double pressed.

Sounds good, I agree it is weird. Maybe someone with a slower internet or computer where they have more of a chance to click twice? Either way we'll keep an eye out for other cases of workflows being duplicated.

Hi @Trey_Anderson, just checking in to see if you've seen anymore workflow duplication since then. If so, we would still be invested in resolving it.

Just marked a solution above in case anyone has a similar issue, if it arises again I can change it and we can investigate further!