bugy / script-server

Web UI for your scripts with execution management
Other
1.52k stars 244 forks source link

/admin broken in Safari because it doesn't support look-behind regex assertions #632

Open dreness opened 1 year ago

dreness commented 1 year ago

Safari 16.3 on macOS 13.2.1 (and probably all earlier versions) can't render /admin because it doesn't (yet) support look-behind regex assertions. The HTTP request succeeds, but the page render fails and the following error is logged to the console:

[Error] SyntaxError: Invalid regular expression: invalid group specifier name
    (anonymous function) (admin.3912c4c1.js:1)

look-behind support has been added to Safari Technology Preview, and /admin loads fine using that browser. It's reasonable to assume this enhancement will make it into the main build of Safari that ships with Apple operating systems.

click here for screenshots

Below is a screenshot of what failure looks like, with the dev console visible to show the error message and also the browser's version string (which is mostly a lie, except for the indicated portion of that string, which matches the version in the app's About window). safari-16_3 This second screenshot is of Safari Tech Preview successfully rendering the admin page. safari-tech-preview

There's nothing for script-server to do about this; I'm just filing the issue for awareness, and to give any affected users the workaround of using Safari Technology Preview until look-behind support lands in Safari.

Cheers, and thanks for this cool project :)

bugy commented 1 year ago

Hi @dreness thanks a lot for the bugreport!