This is not new as we discussed it in Office Hours yesterday. However I wanted to report further (lack of) "progress" and keep it on the radar.
I significantly refactored the problem event handler as there were all kinds of things about it that did not actually work. Most interestingly, a database read that fails still leaves the old data in .data so tests for null, zero, length, undefined, etc. all "succeed" even if the read fails. But I digress. This new code "works" except for the noted issue.
utils.copyToClipboard('foo'); // this works; when we exit 'foo' will be on the clipboard
var x = await azure_share_check.trigger();
console.log('count=' + x['cnt'][0]);
if (x['cnt'][0] == 0) {
await azure_share_upsert.trigger();
}
var y = await azure_share_read.trigger();
console.log('y=' + y['share-guid'][0].toLowerCase());
var s = ('https://methodical.retool.com/embedded/public/e00e83c4-1141-49dd-9a1a-19dd3eb496cf/#share=' + y['share-guid'][0].toLowerCase());
console.log(s);
// this code is broken right now; does nothing
//
utils.copyToClipboard(s);
Note that at least in console mode banners fly by at the top of the screen. The copy of 'foo' to the clipboard goes by first. And then lots of messages about the queries running. Then the copy to clipboard of the long string s goes by. The string is correctly displayed in the pop up message but the actual clipboard does not change from the 'foo' that was set when we entered.