Hi There!
What I’m trying to do:
I have an App that logs in the user and that is based on the official how to guide.
https://anvil.works/docs/how-to/custom-user-auth
It worked fine for the last months but since yesterdey I receive the follwoing error:
Uncaught SyntaxError: Identifier ‘originalPrompt’ has already been declared
What I’ve tried and what’s not working:
I tried to restore it to different versions but all of them show similar errors.
After some digging I tried to copy the app of the how to guide and saw the same error
https://anvil.works/build#clone:3HBGAFAGNJ6FUQZV%3D4NPQMV4R47BAOIHSXTVRLP5R
Also checked different devices, always the same Result:
Clone link (from the how to page):
https://anvil.works/build#clone:3HBGAFAGNJ6FUQZV%3D4NPQMV4R47BAOIHSXTVRLP5R
Since my apps depend on the loginflow and one of them is currently in live testing I’d apprecieate the help.
Greetings,
Mark
What is the prompt.js
file here?
I suspect you are adding the prompt.js
file a couple of times to the window
possibly as a custom component using script tags.
This file probably includes a line.
let originalPrompt =
But you can’t add this file multiple times with that line since you are redeclaring a variable using let
which is disallowed in javascript.
The custom flow dependency doesn’t seem to be the problem here.
Hi @stucork ,
can you reproduce the error on the clone link?
The reason I ask this is that this is the original clone link from this site:
https://anvil.works/docs/how-to/custom-user-auth
So I did not change anything from the clone example. Which means anyone that has or will use this guide runs in this error.
Ok I understand that adding it multiple times results in an error.
I will do some digging and circle back.
Greetings, Mark
After a private conversation the Chrome Widget “Selenium” triggered the error.
After deleting it all apps work fine again.
Just as a Side Note:
We are now using Katalon Screen recoder to automatically test certain parts of our UI logic.
Katalon Recorder is the Selenium IDE-compatible replacement on latest Chrome and Firefox that helps record, play, debug, manage automated tests. Learn more!
Thanks for the outstanding support!
Greetings from Austria
1 Like