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

deps/updates3 #5318

Merged
merged 11 commits into from Aug 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 6 additions & 2 deletions node_modules/@npmcli/fs/lib/common/owner-sync.js
Expand Up @@ -50,11 +50,15 @@ const update = (path, uid, gid) => {
if (uid === stat.uid && gid === stat.gid) {
return
}
} catch (err) {}
} catch {
// ignore errors
}

try {
fs.chownSync(path, uid, gid)
} catch (err) {}
} catch {
// ignore errors
}
}

// accepts a `path` and the `owner` property of an options object and normalizes
Expand Down
8 changes: 6 additions & 2 deletions node_modules/@npmcli/fs/lib/common/owner.js
Expand Up @@ -50,11 +50,15 @@ const update = async (path, uid, gid) => {
if (uid === stat.uid && gid === stat.gid) {
return
}
} catch (err) {}
} catch {
// ignore errors
}

try {
await fs.chown(path, uid, gid)
} catch (err) {}
} catch {
// ignore errors
}
}

// accepts a `path` and the `owner` property of an options object and normalizes
Expand Down
4 changes: 3 additions & 1 deletion node_modules/@npmcli/fs/lib/with-temp-dir.js
Expand Up @@ -27,7 +27,9 @@ const withTempDir = async (root, fn, opts) => {

try {
await rm(target, { force: true, recursive: true })
} catch {}
} catch {
// ignore errors
}

if (err) {
throw err
Expand Down
2 changes: 1 addition & 1 deletion node_modules/@npmcli/fs/package.json
@@ -1,6 +1,6 @@
{
"name": "@npmcli/fs",
"version": "2.1.1",
"version": "2.1.2",
"description": "filesystem utilities for the npm cli",
"main": "lib/index.js",
"files": [
Expand Down
4 changes: 3 additions & 1 deletion node_modules/@npmcli/git/lib/which.js
Expand Up @@ -3,7 +3,9 @@ const which = require('which')
let gitPath
try {
gitPath = which.sync('git')
} catch (e) {}
} catch {
// ignore errors
}

module.exports = (opts = {}) => {
if (opts.git) {
Expand Down
8 changes: 5 additions & 3 deletions node_modules/@npmcli/git/package.json
@@ -1,6 +1,6 @@
{
"name": "@npmcli/git",
"version": "3.0.1",
"version": "3.0.2",
"main": "lib/index.js",
"files": [
"bin/",
Expand Down Expand Up @@ -31,7 +31,9 @@
},
"devDependencies": {
"@npmcli/eslint-config": "^3.0.1",
"@npmcli/template-oss": "3.2.2",
"@npmcli/template-oss": "3.5.0",
"npm-package-arg": "^9.1.0",
"rimraf": "^3.0.2",
"slash": "^3.0.0",
"tap": "^16.0.1"
},
Expand All @@ -52,6 +54,6 @@
"templateOSS": {
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
"windowsCI": false,
"version": "3.2.2"
"version": "3.5.0"
}
}
22 changes: 16 additions & 6 deletions node_modules/@npmcli/move-file/lib/index.js
Expand Up @@ -97,14 +97,19 @@ const moveFile = async (source, destination, options = {}, root = true, symlinks
}
// try to determine what the actual file is so we can create the correct
// type of symlink in windows
let targetStat
let targetStat = 'file'
try {
targetStat = await stat(resolve(dirname(symSource), target))
} catch (err) {}
if (targetStat.isDirectory()) {
targetStat = 'junction'
}
} catch {
// targetStat remains 'file'
}
await symlink(
target,
symDestination,
targetStat && targetStat.isDirectory() ? 'junction' : 'file'
targetStat
)
}))
await rimraf(source)
Expand Down Expand Up @@ -157,14 +162,19 @@ const moveFileSync = (source, destination, options = {}, root = true, symlinks =
}
// try to determine what the actual file is so we can create the correct
// type of symlink in windows
let targetStat
let targetStat = 'file'
try {
targetStat = statSync(resolve(dirname(symSource), target))
} catch (err) {}
if (targetStat.isDirectory()) {
targetStat = 'junction'
}
} catch {
// targetStat remains 'file'
}
symlinkSync(
target,
symDestination,
targetStat && targetStat.isDirectory() ? 'junction' : 'file'
targetStat
)
}
rimrafSync(source)
Expand Down
6 changes: 3 additions & 3 deletions node_modules/@npmcli/move-file/package.json
@@ -1,6 +1,6 @@
{
"name": "@npmcli/move-file",
"version": "2.0.0",
"version": "2.0.1",
"files": [
"bin/",
"lib/"
Expand All @@ -13,7 +13,7 @@
},
"devDependencies": {
"@npmcli/eslint-config": "^3.0.1",
"@npmcli/template-oss": "3.2.2",
"@npmcli/template-oss": "3.5.0",
"tap": "^16.0.1"
},
"scripts": {
Expand Down Expand Up @@ -42,6 +42,6 @@
"author": "GitHub Inc.",
"templateOSS": {
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
"version": "3.2.2"
"version": "3.5.0"
}
}
2 changes: 2 additions & 0 deletions node_modules/bin-links/lib/link-gently.js
Expand Up @@ -64,6 +64,8 @@ const linkGently = async ({ path, to, from, absFrom, force }) => {
if (target.indexOf(path) === 0 || force) {
return rm(to).then(() => CLOBBER)
}
// neither skip nor clobber
return false
})
} else {
// doesn't exist, dir might not either
Expand Down
5 changes: 3 additions & 2 deletions node_modules/bin-links/lib/shim-bin.js
Expand Up @@ -56,19 +56,20 @@ const shimBin = ({ path, to, from, absFrom, force }) => {
}

if (force) {
return
return false
}

return Promise.all(shims.map((s, i) => [s, stats[i]]).map(([s, st]) => {
if (!st) {
return
return false
}
return readCmdShim(s)
.then(target => {
target = resolve(dirname(to), target)
if (target.indexOf(resolve(path)) !== 0) {
return failEEXIST({ from, to, path })
}
return false
}, er => handleReadCmdShimError({ er, from, to }))
}))
})
Expand Down
8 changes: 4 additions & 4 deletions node_modules/bin-links/package.json
@@ -1,6 +1,6 @@
{
"name": "bin-links",
"version": "3.0.1",
"version": "3.0.2",
"description": "JavaScript package binary linker",
"main": "./lib/index.js",
"scripts": {
Expand Down Expand Up @@ -35,10 +35,10 @@
},
"devDependencies": {
"@npmcli/eslint-config": "^3.0.1",
"@npmcli/template-oss": "3.2.2",
"@npmcli/template-oss": "3.5.0",
"mkdirp": "^1.0.3",
"require-inject": "^1.4.4",
"tap": "^15.0.10"
"tap": "^16.0.1"
},
"tap": {
"check-coverage": true,
Expand All @@ -55,6 +55,6 @@
"templateOSS": {
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
"windowsCI": false,
"version": "3.2.2"
"version": "3.5.0"
}
}
2 changes: 1 addition & 1 deletion node_modules/cacache/lib/content/read.js
Expand Up @@ -81,7 +81,7 @@ function readStream (cache, integrity, opts = {}) {
return stream.emit('error', sizeError(size, stat.size))
}

readPipeline(cpath, stat.size, sri, stream)
return readPipeline(cpath, stat.size, sri, stream)
}).catch(err => stream.emit('error', err))

return stream
Expand Down
2 changes: 2 additions & 0 deletions node_modules/cacache/lib/content/write.js
Expand Up @@ -80,9 +80,11 @@ class CacacheWriteStream extends Flush {
// defer this one tick by rejecting a promise on it.
return Promise.reject(e).catch(cb)
}
// eslint-disable-next-line promise/catch-or-return
this.handleContentP.then(
(res) => {
res.integrity && this.emit('integrity', res.integrity)
// eslint-disable-next-line promise/always-return
res.size !== null && this.emit('size', res.size)
cb()
},
Expand Down
1 change: 1 addition & 0 deletions node_modules/cacache/lib/entry-index.js
Expand Up @@ -285,6 +285,7 @@ function lsStream (cache) {
}))
}))
stream.end()
return stream
}).catch(err => stream.emit('error', err))

return stream
Expand Down
1 change: 1 addition & 0 deletions node_modules/cacache/lib/get.js
Expand Up @@ -155,6 +155,7 @@ function getStream (cache, key, opts = {}) {
stream.unshift(memoStream)
}
stream.unshift(src)
return stream
}).catch((err) => stream.emit('error', err))

return stream
Expand Down
2 changes: 1 addition & 1 deletion node_modules/cacache/package.json
@@ -1,6 +1,6 @@
{
"name": "cacache",
"version": "16.1.1",
"version": "16.1.2",
"cache-version": {
"content": "2",
"index": "5"
Expand Down
1 change: 1 addition & 0 deletions node_modules/make-fetch-happen/lib/cache/entry.js
Expand Up @@ -288,6 +288,7 @@ class CacheEntry {
// stick a flag on here so downstream users will know if they can expect integrity events
tee.pipe(cacheStream)
// TODO if the cache write fails, log a warning but return the response anyway
// eslint-disable-next-line promise/catch-or-return
cacheStream.promise().then(cacheWriteResolve, cacheWriteReject)
body.unshift(tee)
body.unshift(this.response.body)
Expand Down
2 changes: 1 addition & 1 deletion node_modules/make-fetch-happen/package.json
@@ -1,6 +1,6 @@
{
"name": "make-fetch-happen",
"version": "10.2.0",
"version": "10.2.1",
"description": "Opinionated, caching, retrying fetch client",
"main": "lib/index.js",
"files": [
Expand Down
24 changes: 13 additions & 11 deletions node_modules/minipass-fetch/lib/body.js
Expand Up @@ -10,7 +10,9 @@ const FetchError = require('./fetch-error.js')
let convert
try {
convert = require('encoding').convert
} catch (e) {}
} catch (e) {
// defer error until textConverted is called
}

const INTERNALS = Symbol('Body internals')
const CONSUME_BODY = Symbol('consumeBody')
Expand Down Expand Up @@ -69,16 +71,16 @@ class Body {
))
}

json () {
return this[CONSUME_BODY]().then(buf => {
try {
return JSON.parse(buf.toString())
} catch (er) {
return Promise.reject(new FetchError(
`invalid json response body at ${
this.url} reason: ${er.message}`, 'invalid-json'))
}
})
async json () {
try {
const buf = await this[CONSUME_BODY]()
return JSON.parse(buf.toString())
} catch (er) {
throw new FetchError(
`invalid json response body at ${this.url} reason: ${er.message}`,
'invalid-json'
)
}
}

text () {
Expand Down
7 changes: 4 additions & 3 deletions node_modules/minipass-fetch/package.json
@@ -1,6 +1,6 @@
{
"name": "minipass-fetch",
"version": "2.1.0",
"version": "2.1.1",
"description": "An implementation of window.fetch in Node.js using Minipass streams",
"license": "MIT",
"main": "lib/index.js",
Expand All @@ -23,10 +23,11 @@
},
"devDependencies": {
"@npmcli/eslint-config": "^3.0.1",
"@npmcli/template-oss": "3.1.2",
"@npmcli/template-oss": "3.5.0",
"@ungap/url-search-params": "^0.2.2",
"abort-controller": "^3.0.0",
"abortcontroller-polyfill": "~1.7.3",
"encoding": "^0.1.13",
"form-data": "^4.0.0",
"nock": "^13.2.4",
"parted": "^0.1.1",
Expand Down Expand Up @@ -61,6 +62,6 @@
"author": "GitHub Inc.",
"templateOSS": {
"//@npmcli/template-oss": "This file is partially managed by @npmcli/template-oss. Edits may be overwritten.",
"version": "3.1.2"
"version": "3.5.0"
}
}
12 changes: 7 additions & 5 deletions node_modules/normalize-package-data/lib/extract_description.js
Expand Up @@ -11,12 +11,14 @@ function extractDescription (d) {
// the first block of text before the first heading
// that isn't the first line heading
d = d.trim().split('\n')
for (var s = 0; d[s] && d[s].trim().match(/^(#|$)/); s++) {
;
let s = 0
while (d[s] && d[s].trim().match(/^(#|$)/)) {
s++
}
var l = d.length
for (var e = s + 1; e < l && d[e].trim(); e++) {
;
const l = d.length
let e = s + 1
while (e < l && d[e].trim()) {
e++
}
return d.slice(s, e).join(' ').trim()
}