What does this mean?: Workflow error - trying to retrieve missing element state

Seeing that a workflow doesn’t appear to be working, I viewed the server log.

The message is this: “Workflow error - trying to retrieve missing element state”
image

Here’s what the workflow looks like:


steps:

  1. terminate if the dropdown value is empty.
  2. set the custom state DoingUpdates to “yes”, signaling that updates are underway. This should prevent the workflow from being triggered again when the input is reset.
  3. and 4. set custom states in the reusable element reaction.
  4. triggers the workflow Create New Action in the reusable element reaction.
  5. and 7. set focus and reset inputs on the page.
  6. pause just because it might help(?) I have no idea when a pause is needed. In this case, I added it, thinking the reset of inputs might leave the input element in some kind of limbo state but the pause would allow things to settle before step 9 which says it’s okay to do another update.
  7. set the custom state DoingUpdates to “no”, signaling that the coast is clear and the workflow can be triggered again.

Why is the workflow being triggered again before its work is done? It appears to be triggering before the reset of inputs. I think so because the log doesn’t show that the Create a new Action step is run in the reusable element workflow.

This is from the Bubble Manual:

Execution

When a workflow is triggered in run mode and hits a trigger a custom event action, the first workflow will pause, the custom event will be run till completion, and the first workflow will resume.

It doesn’t appear that everything has truly paused on the client while the triggered workflow is running.

UPDATE:
The next time I ran a test, this popped up:
image

Is this indicative of a deeper problem that sometimes manifests as described above?

This topic was automatically closed after 70 days. New replies are no longer allowed.