Relations removed by automations

Hello!

I’ve built an automation that’s supposed to relate an item from app A to an item from app B. The trigger occurs upon creation (i.e., when an item is created in app A, it should relate it to an item in app B). The issue I’m facing is when two items are created at the same time, or within a few seconds of eachother: the automations are running at nearly the same time, causing the relation to be removed shortly after it is made.

image

It’s important to notice that there isn’t any actions to remove relations on my automation…

2 Likes

I’m curious - how is it linking to the related item? Is it a search operation or something else? That might help the devs to identify the issue better. Maybe you could also add a screenshot or description of your automation.

2 Likes

There’s a relation field on app A that relates to multiple records of app “OC | Itens”.

So my automation gets records of a view and filter the records following established parameters. If it finds any record that meets these parameters, it should take these multiple items on the relation field on app A and add them to the relation field on app B.

A similar case is happening on another organization with an automation I built that follows the same logic.

1 Like

Hi @agnes.farias,

thank you so much for the report! We believe we already have a good idea of what’s causing your issue. To provide a solution, we need to know whether you’re using one or two automations for the process.

If you’re using two automations, the solution would be to merge them into one. If you’re using only one automation, we would need a screenshot of the complete automation to assist you further. Feel free to send me the screenshot as a private message here in the community if it contains sensitive data.

Here’s some background to help you understand the issue: The Tape API (which the Tape automations use) currently only supports a “set” operation per field. Even though “Add records” is selected in the editor, it always sets both the existing and new records in one set operation. Since each customer is currently allocated two parallel runs to process automations, two flows that are triggered at the exactly same time and write to the same field in the same record have a high chance to overwrite each other. In very rare cases, this can also happen with a single automation, but this requires the automation to be triggered twice at the same time, making it run in parallel twice in the two slots, which is very difficult to reproduce.

Best regards,
Leo

2 Likes

Hi @Leo , thank you for your time and for the background.

I’m only using one automation. The system I built on Tape is responsible to manage purchase orders from a school, and this app should receive orders from different departments and merge them into one. My automation is set on a app not available for the school (app A) and it runs a loop through a list of classifications (for instance: food, cleaning supplies, etc.) and gather all purchase items related to this classification and create an item on app B for it OR relates the purchase items if an item for this classification already exists there.





2 Likes