"on submit" action not triggered the first time

Hi all,

I’m having a strange issue that may be a bug.
I couldn’t find any related post on the forum, but maybe you’ll see what I’m missing here.

I have a “save” action that should be triggered when my form is submitted.
The action is basic, is writes the value of a calculated attribute and display a success notification. I added another notification before for debug reason.

It looks like this “save” action is not triggered the first time.
Here is the video with my configuration and the issue :

Any idea about what may be the issue?
Thanks for your help!

On Submit actions run very quickly and not necessarily synchronously. It’s possible that the newly added row had not been fully added with all computed columns processed by the time the On Submit actions run. I usually avoid On Submit if I can for this reason.

I would try introducing a short Wait or Wait For action at the beginning of your action flow to give the newly added row a chance to get fully established before running the rest of your actions.

2 Likes

Thanks Jeff.

I’ve actually tried this solution and added a wait, but the wait itself wasn’t executed. Actually, the whole submission isn’t executed, not only the On Submit action. We can see in the video that the attribute “timer” remains the same after I’ve submit the first time. I removed the On submit action and I still have this problem : the first submit is simply skipped.

I suspect that a javascript function is causing this issue.
I have a function that serialise all questions of the quizz into a Json.
I’ll try to remove this column and see if that changes anything.

I’ll keep you posted.
Thanks again.

1 Like

Salut Xavier,

The JSON you create is with a JSON object/template or a string? I’ve been running into issues with the objects/template, but it always work with a string. Not sure if it’s relevant for your case but just sharing.

1 Like

Based on what I’m seeing in your video, this feels like a bug. I’m not seeing anything obviously wrong unless there is a sync issue. What are you using for a data source for your tables?

It’s a string that I write with a javascript

1 Like

Google sheet.
I couldn’t use the Glide tables here since those data needs to be synced with another database.

I’d be more suspicious if it was Airtable or Excel. I’ve never had issues with Google Sheets. I think you may want to submit a support ticket.

1 Like

Will do.
I’ve just removed all JS column in case it caused some latency, but I still have the issue.

1 Like

Hi all,

I reported a bug … but unfortunately the support link was broken :sweat_smile: (Glide).

I managed however to find what caused the problem.
It’s this column attribute :

The good new is that I don’t think I need it actually.
I hope this can be useful to anybody running into this issue in the future.

So you think using a Column Value component prevented your actions from running? Still seems odd. Just curious why you think that component was the problem?

Well, I’ve actually deleted my components until I couldn’t reproduce, starting with what could cause problem (the HTML field and this hidden field). The exception was no longer raised in the js console, and I couldn’t reproduce the issue.

1 Like

Interesting.