diff --git a/node_modules/pacote/CHANGELOG.md b/node_modules/pacote/CHANGELOG.md index c127fb850078b..4ed92beb68213 100644 --- a/node_modules/pacote/CHANGELOG.md +++ b/node_modules/pacote/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. + +## [9.5.8](https://github.com/npm/pacote/compare/v9.5.7...v9.5.8) (2019-08-20) + + + ## [9.5.7](https://github.com/npm/pacote/compare/v9.5.6...v9.5.7) (2019-08-19) diff --git a/node_modules/pacote/lib/fetchers/registry/manifest.js b/node_modules/pacote/lib/fetchers/registry/manifest.js index d29ec71c3375e..00deb13af236d 100644 --- a/node_modules/pacote/lib/fetchers/registry/manifest.js +++ b/node_modules/pacote/lib/fetchers/registry/manifest.js @@ -27,7 +27,7 @@ function getManifest (spec, opts) { includeDeprecated: opts.includeDeprecated }) } catch (err) { - if (err.code === 'ETARGET' && packument._cached && !opts.offline) { + if ((err.code === 'ETARGET' || err.code === 'E403') && packument._cached && !opts.offline) { opts.log.silly( 'registry:manifest', `no matching version for ${spec.name}@${spec.fetchSpec} in the cache. Forcing revalidation.` diff --git a/node_modules/pacote/node_modules/npm-pick-manifest/CHANGELOG.md b/node_modules/pacote/node_modules/npm-pick-manifest/CHANGELOG.md deleted file mode 100644 index 2112665f7572e..0000000000000 --- a/node_modules/pacote/node_modules/npm-pick-manifest/CHANGELOG.md +++ /dev/null @@ -1,133 +0,0 @@ -# Change Log - -All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. - - -## [2.2.3](https://github.com/zkat/npm-pick-manifest/compare/v2.2.2...v2.2.3) (2018-10-31) - - -### Bug Fixes - -* **enjoyBy:** rework semantics for enjoyBy again ([5e89b62](https://github.com/zkat/npm-pick-manifest/commit/5e89b62)) - - - - -## [2.2.2](https://github.com/zkat/npm-pick-manifest/compare/v2.2.1...v2.2.2) (2018-10-31) - - -### Bug Fixes - -* **enjoyBy:** rework semantics for enjoyBy ([5684f45](https://github.com/zkat/npm-pick-manifest/commit/5684f45)) - - - - -## [2.2.1](https://github.com/zkat/npm-pick-manifest/compare/v2.2.0...v2.2.1) (2018-10-30) - - - - -# [2.2.0](https://github.com/zkat/npm-pick-manifest/compare/v2.1.0...v2.2.0) (2018-10-30) - - -### Bug Fixes - -* **audit:** npm audit fix --force ([d5ae6c4](https://github.com/zkat/npm-pick-manifest/commit/d5ae6c4)) - - -### Features - -* **enjoyBy:** add opts.enjoyBy option to filter versions by date ([0b8a790](https://github.com/zkat/npm-pick-manifest/commit/0b8a790)) - - - - -# [2.1.0](https://github.com/zkat/npm-pick-manifest/compare/v2.0.1...v2.1.0) (2017-10-18) - - -### Features - -* **selection:** allow manually disabling deprecation skipping ([0d239d3](https://github.com/zkat/npm-pick-manifest/commit/0d239d3)) - - - - -## [2.0.1](https://github.com/zkat/npm-pick-manifest/compare/v2.0.0...v2.0.1) (2017-10-18) - - - - -# [2.0.0](https://github.com/zkat/npm-pick-manifest/compare/v1.0.4...v2.0.0) (2017-10-03) - - -### Bug Fixes - -* **license:** relicense project according to npm policy (#3) ([ed743a0](https://github.com/zkat/npm-pick-manifest/commit/ed743a0)) - - -### Features - -* **selection:** Avoid matching deprecated packages if possible ([3fc6c3a](https://github.com/zkat/npm-pick-manifest/commit/3fc6c3a)) - - -### BREAKING CHANGES - -* **selection:** deprecated versions may be skipped now -* **license:** This moves the license from CC0 to ISC and properly documents the copyright as belonging to npm, Inc. - - - - -## [1.0.4](https://github.com/zkat/npm-pick-manifest/compare/v1.0.3...v1.0.4) (2017-06-29) - - -### Bug Fixes - -* **npa:** bump npa version for bugfixes ([7cdaca7](https://github.com/zkat/npm-pick-manifest/commit/7cdaca7)) -* **semver:** use loose semver parsing for *all* ops ([bbc0daa](https://github.com/zkat/npm-pick-manifest/commit/bbc0daa)) - - - - -## [1.0.3](https://github.com/zkat/npm-pick-manifest/compare/v1.0.2...v1.0.3) (2017-05-04) - - -### Bug Fixes - -* **semver:** use semver.clean() instead ([f4133b5](https://github.com/zkat/npm-pick-manifest/commit/f4133b5)) - - - - -## [1.0.2](https://github.com/zkat/npm-pick-manifest/compare/v1.0.1...v1.0.2) (2017-05-04) - - -### Bug Fixes - -* **picker:** spaces in `wanted` prevented match ([97a7d0a](https://github.com/zkat/npm-pick-manifest/commit/97a7d0a)) - - - - -## [1.0.1](https://github.com/zkat/npm-pick-manifest/compare/v1.0.0...v1.0.1) (2017-04-24) - - -### Bug Fixes - -* **deps:** forgot to add semver ([1876f4f](https://github.com/zkat/npm-pick-manifest/commit/1876f4f)) - - - - -# 1.0.0 (2017-04-24) - - -### Features - -* **api:** initial implementation. ([b086912](https://github.com/zkat/npm-pick-manifest/commit/b086912)) - - -### BREAKING CHANGES - -* **api:** ex nihilo diff --git a/node_modules/pacote/node_modules/npm-pick-manifest/LICENSE.md b/node_modules/pacote/node_modules/npm-pick-manifest/LICENSE.md deleted file mode 100644 index 8d28acf866d93..0000000000000 --- a/node_modules/pacote/node_modules/npm-pick-manifest/LICENSE.md +++ /dev/null @@ -1,16 +0,0 @@ -ISC License - -Copyright (c) npm, Inc. - -Permission to use, copy, modify, and/or distribute this software for -any purpose with or without fee is hereby granted, provided that the -above copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE COPYRIGHT HOLDER DISCLAIMS -ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE -COPYRIGHT HOLDER BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR -CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS -OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE -OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE -USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/node_modules/pacote/node_modules/npm-pick-manifest/README.md b/node_modules/pacote/node_modules/npm-pick-manifest/README.md deleted file mode 100644 index a9a027bfcb460..0000000000000 --- a/node_modules/pacote/node_modules/npm-pick-manifest/README.md +++ /dev/null @@ -1,84 +0,0 @@ -# npm-pick-manifest [![npm version](https://img.shields.io/npm/v/npm-pick-manifest.svg)](https://npm.im/npm-pick-manifest) [![license](https://img.shields.io/npm/l/npm-pick-manifest.svg)](https://npm.im/npm-pick-manifest) [![Travis](https://img.shields.io/travis/zkat/npm-pick-manifest.svg)](https://travis-ci.org/zkat/npm-pick-manifest) [![AppVeyor](https://ci.appveyor.com/api/projects/status/github/zkat/npm-pick-manifest?svg=true)](https://ci.appveyor.com/project/zkat/npm-pick-manifest) [![Coverage Status](https://coveralls.io/repos/github/zkat/npm-pick-manifest/badge.svg?branch=latest)](https://coveralls.io/github/zkat/npm-pick-manifest?branch=latest) - -[`npm-pick-manifest`](https://github.com/zkat/npm-pick-manifest) is a standalone -implementation of [npm](https://npmjs.com)'s semver range resolution algorithm. - -## Install - -`$ npm install --save npm-pick-manifest` - -## Table of Contents - -* [Example](#example) -* [Features](#features) -* [Contributing](#contributing) -* [API](#api) - * [`pickManifest()`](#pick-manifest) - -### Example - -```javascript -const pickManifest = require('npm-pick-manifest') - -fetch('https://registry.npmjs.org/npm-pick-manifest').then(res => { - return res.json() -}).then(packument => { - return pickManifest(packument, '^1.0.0') -}) // get same manifest as npm would get if you `npm i npm-pick-manifest@^1.0.0` -``` - -### Features - -* Uses npm's exact semver resolution algorithm -* Supports ranges, tags, and versions - -### Contributing - -The npm-pick-manifest team enthusiastically welcomes contributions and project participation! -There's a bunch of things you can do if you want to contribute! The [Contributor -Guide](CONTRIBUTING.md) has all the information you need for everything from -reporting bugs to contributing entire new features. Please don't hesitate to -jump in if you'd like to, or even ask us questions if something isn't clear. - -### API - -#### `> pickManifest(packument, selector, [opts]) -> manifest` - -Returns the manifest that matches `selector`, or throws an error. - -Packuments are anything returned by metadata URLs from the npm registry. That -is, they're objects with the following shape (only fields used by -`npm-pick-manifest` included): - -```javascript -{ - name: 'some-package', - 'dist-tags': { - foo: '1.0.1' - }, - versions: { - '1.0.0': { version: '1.0.0' }, - '1.0.1': { version: '1.0.1' }, - '1.0.2': { version: '1.0.2' }, - '2.0.0': { version: '2.0.0' } - } -} -``` - -The algorithm will follow npm's algorithm for semver resolution, and only `tag`, -`range`, and `version` selectors are supported. - -The function will throw `ETARGET` if there was no matching manifest, and -`ENOVERSIONS` if the packument object has no valid versions in `versions`. - -If `opts.defaultTag` is provided, it will be used instead of `latest`. That is, -if that tag matches the selector, it will be used, even if a higher available -version matches the range. - -If `opts.enjoyBy` is provided, it should be something that can be passed to `new -Date(x)`, such as a `Date` object or a timestamp string. It will be used to -filter the selected versions such that only versions less than or equal to -`enjoyBy` are considered. - -If `opts.includeDeprecated` passed in as true, deprecated versions will be -selected. By default, deprecated versions other than `defaultTag` are ignored. diff --git a/node_modules/pacote/node_modules/npm-pick-manifest/index.js b/node_modules/pacote/node_modules/npm-pick-manifest/index.js deleted file mode 100644 index d9a8373e57f14..0000000000000 --- a/node_modules/pacote/node_modules/npm-pick-manifest/index.js +++ /dev/null @@ -1,121 +0,0 @@ -'use strict' - -const figgyPudding = require('figgy-pudding') -const npa = require('npm-package-arg') -const semver = require('semver') - -const PickerOpts = figgyPudding({ - defaultTag: { default: 'latest' }, - enjoyBy: {}, - includeDeprecated: { default: false } -}) - -module.exports = pickManifest -function pickManifest (packument, wanted, opts) { - opts = PickerOpts(opts) - const time = opts.enjoyBy && packument.time && +(new Date(opts.enjoyBy)) - const spec = npa.resolve(packument.name, wanted) - const type = spec.type - if (type === 'version' || type === 'range') { - wanted = semver.clean(wanted, true) || wanted - } - const distTags = packument['dist-tags'] || {} - const versions = Object.keys(packument.versions || {}).filter(v => { - return semver.valid(v, true) - }) - - function enjoyableBy (v) { - return !time || ( - packument.time[v] && time >= +(new Date(packument.time[v])) - ) - } - - let err - - if (!versions.length) { - err = new Error(`No valid versions available for ${packument.name}`) - err.code = 'ENOVERSIONS' - err.name = packument.name - err.type = type - err.wanted = wanted - throw err - } - - let target - - if (type === 'tag' && enjoyableBy(distTags[wanted])) { - target = distTags[wanted] - } else if (type === 'version') { - target = wanted - } else if (type !== 'range' && enjoyableBy(distTags[wanted])) { - throw new Error('Only tag, version, and range are supported') - } - - const tagVersion = distTags[opts.defaultTag] - - if ( - !target && - tagVersion && - packument.versions[tagVersion] && - enjoyableBy(tagVersion) && - semver.satisfies(tagVersion, wanted, true) - ) { - target = tagVersion - } - - if (!target && !opts.includeDeprecated) { - const undeprecated = versions.filter(v => !packument.versions[v].deprecated && enjoyableBy(v) - ) - target = semver.maxSatisfying(undeprecated, wanted, true) - } - if (!target) { - const stillFresh = versions.filter(enjoyableBy) - target = semver.maxSatisfying(stillFresh, wanted, true) - } - - if (!target && wanted === '*' && enjoyableBy(tagVersion)) { - // This specific corner is meant for the case where - // someone is using `*` as a selector, but all versions - // are pre-releases, which don't match ranges at all. - target = tagVersion - } - - if ( - !target && - time && - type === 'tag' && - distTags[wanted] && - !enjoyableBy(distTags[wanted]) - ) { - const stillFresh = versions.filter(v => - enjoyableBy(v) && semver.lte(v, distTags[wanted], true) - ).sort(semver.rcompare) - target = stillFresh[0] - } - - const manifest = ( - target && - packument.versions[target] - ) - if (!manifest) { - err = new Error( - `No matching version found for ${packument.name}@${wanted}${ - opts.enjoyBy - ? ` with an Enjoy By date of ${ - new Date(opts.enjoyBy).toLocaleString() - }. Maybe try a different date?` - : '' - }` - ) - err.code = 'ETARGET' - err.name = packument.name - err.type = type - err.wanted = wanted - err.versions = versions - err.distTags = distTags - err.defaultTag = opts.defaultTag - throw err - } else { - return manifest - } -} diff --git a/node_modules/pacote/node_modules/npm-pick-manifest/package.json b/node_modules/pacote/node_modules/npm-pick-manifest/package.json deleted file mode 100644 index dcf9d89740935..0000000000000 --- a/node_modules/pacote/node_modules/npm-pick-manifest/package.json +++ /dev/null @@ -1,82 +0,0 @@ -{ - "_from": "npm-pick-manifest@^2.2.3", - "_id": "npm-pick-manifest@2.2.3", - "_inBundle": false, - "_integrity": "sha512-+IluBC5K201+gRU85vFlUwX3PFShZAbAgDNp2ewJdWMVSppdo/Zih0ul2Ecky/X7b51J7LrrUAP+XOmOCvYZqA==", - "_location": "/pacote/npm-pick-manifest", - "_phantomChildren": {}, - "_requested": { - "type": "range", - "registry": true, - "raw": "npm-pick-manifest@^2.2.3", - "name": "npm-pick-manifest", - "escapedName": "npm-pick-manifest", - "rawSpec": "^2.2.3", - "saveSpec": null, - "fetchSpec": "^2.2.3" - }, - "_requiredBy": [ - "/pacote" - ], - "_resolved": "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-2.2.3.tgz", - "_shasum": "32111d2a9562638bb2c8f2bf27f7f3092c8fae40", - "_spec": "npm-pick-manifest@^2.2.3", - "_where": "/Users/isaacs/dev/npm/cli/node_modules/pacote", - "author": { - "name": "Kat Marchán", - "email": "kzm@sykosomatic.org" - }, - "bugs": { - "url": "https://github.com/zkat/npm-pick-manifest/issues" - }, - "bundleDependencies": false, - "config": { - "nyc": { - "exclude": [ - "node_modules/**", - "test/**" - ] - } - }, - "dependencies": { - "figgy-pudding": "^3.5.1", - "npm-package-arg": "^6.0.0", - "semver": "^5.4.1" - }, - "deprecated": false, - "description": "Resolves a matching manifest from a package metadata document according to standard npm semver resolution rules.", - "devDependencies": { - "nyc": "^13.1.0", - "standard": "^10.0.3", - "standard-version": "^4.4.0", - "tap": "^12.0.1", - "weallbehave": "^1.2.0", - "weallcontribute": "^1.0.8" - }, - "files": [ - "*.js" - ], - "homepage": "https://github.com/zkat/npm-pick-manifest#readme", - "keywords": [ - "npm", - "semver", - "package manager" - ], - "license": "ISC", - "main": "index.js", - "name": "npm-pick-manifest", - "repository": { - "type": "git", - "url": "git+https://github.com/zkat/npm-pick-manifest.git" - }, - "scripts": { - "postrelease": "npm publish && git push --follow-tags", - "prerelease": "npm t", - "pretest": "standard", - "release": "standard-version -s", - "test": "tap -J --100 --coverage test/*.js", - "update-coc": "weallbehave -o . && git add CODE_OF_CONDUCT.md && git commit -m 'docs(coc): updated CODE_OF_CONDUCT.md'", - "update-contrib": "weallcontribute -o . && git add CONTRIBUTING.md && git commit -m 'docs(contributing): updated CONTRIBUTING.md'" - }, - "version": "2.2.3" -} diff --git a/node_modules/pacote/package.json b/node_modules/pacote/package.json index d4456f158738b..58826586a3520 100644 --- a/node_modules/pacote/package.json +++ b/node_modules/pacote/package.json @@ -1,8 +1,8 @@ { - "_from": "pacote@9.5.7", - "_id": "pacote@9.5.7", + "_from": "pacote@9.5.8", + "_id": "pacote@9.5.8", "_inBundle": false, - "_integrity": "sha512-hh6TCqfblM+UEwUIyQrCIlLf7i0LrlYx2ovsa5yXPWWiXSeRpQVwVTD+QfYrBoSGIbdwtN6YP9AEro/kz5F4Mw==", + "_integrity": "sha512-0Tl8Oi/K0Lo4MZmH0/6IsT3gpGf9eEAznLXEQPKgPq7FscnbUOyopnVpwXlnQdIbCUaojWy1Wd7VMyqfVsRrIw==", "_location": "/pacote", "_phantomChildren": { "safe-buffer": "5.1.2", @@ -11,12 +11,12 @@ "_requested": { "type": "version", "registry": true, - "raw": "pacote@9.5.7", + "raw": "pacote@9.5.8", "name": "pacote", "escapedName": "pacote", - "rawSpec": "9.5.7", + "rawSpec": "9.5.8", "saveSpec": null, - "fetchSpec": "9.5.7" + "fetchSpec": "9.5.8" }, "_requiredBy": [ "#USER", @@ -24,9 +24,9 @@ "/libcipm", "/libnpm" ], - "_resolved": "https://registry.npmjs.org/pacote/-/pacote-9.5.7.tgz", - "_shasum": "71eed4696809bdd72ce61228b8f018eab34e21cf", - "_spec": "pacote@9.5.7", + "_resolved": "https://registry.npmjs.org/pacote/-/pacote-9.5.8.tgz", + "_shasum": "23480efdc4fa74515855c9ecf39cf64078f99786", + "_spec": "pacote@9.5.8", "_where": "/Users/isaacs/dev/npm/cli", "author": { "name": "Kat Marchán", @@ -63,7 +63,7 @@ "normalize-package-data": "^2.4.0", "npm-package-arg": "^6.1.0", "npm-packlist": "^1.1.12", - "npm-pick-manifest": "^2.2.3", + "npm-pick-manifest": "^3.0.0", "npm-registry-fetch": "^4.0.0", "osenv": "^0.1.5", "promise-inflight": "^1.0.1", @@ -119,5 +119,5 @@ "update-coc": "weallbehave -o . && git add CODE_OF_CONDUCT.md && git commit -m 'docs(coc): updated CODE_OF_CONDUCT.md'", "update-contrib": "weallcontribute -o . && git add CONTRIBUTING.md && git commit -m 'docs(contributing): updated CONTRIBUTING.md'" }, - "version": "9.5.7" + "version": "9.5.8" } diff --git a/package-lock.json b/package-lock.json index c763d1ec5c6d2..d7d138bc4c07a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4385,9 +4385,9 @@ } }, "pacote": { - "version": "9.5.7", - "resolved": "https://registry.npmjs.org/pacote/-/pacote-9.5.7.tgz", - "integrity": "sha512-hh6TCqfblM+UEwUIyQrCIlLf7i0LrlYx2ovsa5yXPWWiXSeRpQVwVTD+QfYrBoSGIbdwtN6YP9AEro/kz5F4Mw==", + "version": "9.5.8", + "resolved": "https://registry.npmjs.org/pacote/-/pacote-9.5.8.tgz", + "integrity": "sha512-0Tl8Oi/K0Lo4MZmH0/6IsT3gpGf9eEAznLXEQPKgPq7FscnbUOyopnVpwXlnQdIbCUaojWy1Wd7VMyqfVsRrIw==", "requires": { "bluebird": "^3.5.3", "cacache": "^12.0.2", @@ -4405,7 +4405,7 @@ "normalize-package-data": "^2.4.0", "npm-package-arg": "^6.1.0", "npm-packlist": "^1.1.12", - "npm-pick-manifest": "^2.2.3", + "npm-pick-manifest": "^3.0.0", "npm-registry-fetch": "^4.0.0", "osenv": "^0.1.5", "promise-inflight": "^1.0.1", @@ -4428,16 +4428,6 @@ "safe-buffer": "^5.1.2", "yallist": "^3.0.0" } - }, - "npm-pick-manifest": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/npm-pick-manifest/-/npm-pick-manifest-2.2.3.tgz", - "integrity": "sha512-+IluBC5K201+gRU85vFlUwX3PFShZAbAgDNp2ewJdWMVSppdo/Zih0ul2Ecky/X7b51J7LrrUAP+XOmOCvYZqA==", - "requires": { - "figgy-pudding": "^3.5.1", - "npm-package-arg": "^6.0.0", - "semver": "^5.4.1" - } } } }, diff --git a/package.json b/package.json index 18fae528758cd..c5ae2591a5a7d 100644 --- a/package.json +++ b/package.json @@ -110,7 +110,7 @@ "once": "~1.4.0", "opener": "^1.5.1", "osenv": "^0.1.5", - "pacote": "^9.5.7", + "pacote": "^9.5.8", "path-is-inside": "~1.0.2", "promise-inflight": "~1.0.1", "qrcode-terminal": "^0.12.0",