Hey @cmlee! Yes, asynchronicity definitely plays a part here but you've handled that well by awaiting the call to setValue. For performance purposes, by default, the value of external (to the JS query) variables is only read when the JS query is initially called. In order to refresh the value within the JS query itself, you need to check the Keep variable references inside the query in sync with your app. checkbox on the advanced tab of the query editor.
Here's this JS query run without and with that checkbox checked.
Hope this helps clarify what's going on!


