Data is not immediately available after running "set variable" in runjs
Version Information
Environment
- ToolJet | v1.26.1 (docker)
What is the expected behaviour?
Use actions.setVariable to set the global variable and then read variables to get the data.
What is the current behaviour?
I got undefined.
How to reproduce the issue?
- Reload page.
- Execute the following runjs code.
actions.setVariable('t', 'yes');
alert(variables.t);
Screenshots or Screencast

Please provide any traces or logs that could help here.
Any possible solutions?
Can you identify the location in the driver source code where the problem exists?
If the bug is confirmed, would you be willing to submit a PR?
Hey @bestpika , this seems to be a valid bug that needs to be fixed. We'll get to it as soon as possible.
I got a error running online
Running this in preview mode

i got this error

this error not hapen if i click in preview button , see ..

PS: Similar to this: https://github.com/ToolJet/ToolJet/issues/4444
@ricardojlrufino The change in number #4445 (#4444) did not fix my problem. I am now running a docker image of v1.28.4. I still get the same result by running the code I provided above.
I am getting the same issue!
Tooljet version: tooljet/tooljet-ce:v2.5.0
Ref - #8242