monperrus / crawler-user-agents

Syntactic patterns of HTTP user-agents used by bots / robots / crawlers / scrapers / spiders. pull-request welcome :star:
MIT License
1.13k stars 243 forks source link

Automatic npm continuous deployments broken #277

Closed JBYoshi closed 3 years ago

JBYoshi commented 3 years ago

Found this error in the Travis CI logs:

$ npm version `node -e 'pacote=require("pacote");pacote.manifest("crawler-user-agents").then(pkgJson => { console.log(pkgJson.version); });'`
(node:3731) UnhandledPromiseRejectionWarning: ReferenceError: URL is not defined
    at regKeyFromURI (/home/travis/build/monperrus/crawler-user-agents/node_modules/npm-registry-fetch/auth.js:7:18)
    at getAuth (/home/travis/build/monperrus/crawler-user-agents/node_modules/npm-registry-fetch/auth.js:49:18)
    at regFetch (/home/travis/build/monperrus/crawler-user-agents/node_modules/npm-registry-fetch/index.js:55:16)
    at RegistryFetcher.packument (/home/travis/build/monperrus/crawler-user-agents/node_modules/pacote/lib/registry.js:86:15)
    at RegistryFetcher.manifest (/home/travis/build/monperrus/crawler-user-agents/node_modules/pacote/lib/registry.js:117:17)
    at Object.manifest (/home/travis/build/monperrus/crawler-user-agents/node_modules/pacote/lib/index.js:16:45)
    at [eval]:1:33
    at ContextifyScript.Script.runInThisContext (vm.js:50:33)
    at Object.runInThisContext (vm.js:139:38)
    at Object.<anonymous> ([eval]-wrapper:6:22)
(node:3731) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:3731) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
monperrus commented 3 years ago

Thanks for noticing this.

https://github.com/monperrus/crawler-user-agents/commit/0303036560bdafae0b05be95b78a13287561e6a0 is the fix

And thus 1.0.81 is the latest version: https://www.npmjs.com/package/crawler-user-agents/v/1.0.81