While playing with some jquery/ajax stuff in node.js, I think I’ve hit a bug in the whatwg-url module used by jsdom.
It’s unable to parse certain valid URLs such as: "https://r3---sn-p5qlsnz6.googlevideo.com/" and throws "TypeError: Invalid URL".
I think the problem is with the “r3---sn” part of the hostname.Can you file an issue on the repo, with a small code sample that reproduces the problem?
--
You received this message because you are subscribed to the Google Groups "jsdom" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
jsdom+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
var url = "https://r3---sn-p5qlsnz6.googlevideo.com/";
parseURL = require("whatwg-url").parseURL;
var result = parseURL(url);../node_modules/whatwg-url/lib/url-state-machine.js:1151
throw new TypeError("Invalid URL");
^
TypeError: Invalid URL
at Object.module.exports.basicURLParse (../node_modules/whatwg-url/lib/url-state-machine.js:1151:11)
at module.exports.parseURL (../node_modules/whatwg-url/lib/url-state-machine.js:1189:25)
at Object.<anonymous> (test.js:5:14)