Strange JS TruClient error related to arguments ...

I have a bunch of Wait JS calls like this, where pRandTimeShort is something between 1s and 3s:

When I run this in the Controller I get these errors all over the place:

t=00170093ms: Error -205177: ** 3: Wait [Exception] seconds ** failed - an argument is invalid:
'Interval'. Error: JS arguments are not supported while an authentication dialog box is opened. Use plain or parameter values. Snapshot Info [MSH 2 0] [MsgId: MERR-205177]

I've never seen this before, and have no idea what they mean by "while an authentication dialog box is opened."

Any ideas?