Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: Failed to construct 'URL': Invalid URL in Microsoft Edge #367

Open
nametable opened this issue Jan 24, 2025 · 1 comment
Open

Comments

@nametable
Copy link

When running a simple $RefParser.resolve in a webworker in Microsoft Edge, I am experiencing an error that it Failed to construct 'URL'. This error does not occur in Chrome or Firefox. I suspect this error is caused by a difference in behavior between the constructor for URL in Chrome/Firefox/Edge.

System details:
Firefox Version: 133.0.3
Chromium Version: 132.0.6834.83
Edge Version: 131.0.2903.112
OS: Ubuntu 24.04

Reproduction repository: https://github.com/nametable/json-schema-ref-parser-webworker-bad-url-repro

@jonluca
Copy link
Collaborator

jonluca commented Jan 24, 2025

This is odd, looks like edge doesn't like the invalid protocol that we use to check if a url is relative or now.

I've changed it to a hardcoded non existant url.

Looks like we're having issues cutting a release but hopefully @philsturgeon can add me to the org on npm so we can swap out the token.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants