Skip to content

Commit 1cf5b3b

Browse files
committed
ci(bun): fix rebased migration regressions
## Summary - keep sparse CI and OCI installs complete - restore fail-closed Bun lock traversal and exact attribution refresh - remove redundant fallback branches exposed by current lint ## Why Sparse jobs invoke the Node setup action, which reads package.json to select the pinned Bun version. The OCI build also needs trusted dependency lifecycle scripts while skipping only the package prepare hook. The extracted lock reader had lost the previous parser validation and ancestor/workspace resolution, allowing malformed or incomplete locks to silently shrink license attribution. Single-version rows also retained stale registry metadata. ## Test plan - npm run test:scripts - npm run lint - node scripts/generate-3rdparty-licenses.js --check - changed-line c8 coverage for the affected scripts
1 parent 9bc3200 commit 1cf5b3b

11 files changed

Lines changed: 332 additions & 128 deletions

.github/workflows/all-green.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ jobs:
2424
sparse-checkout: |
2525
.github
2626
bunfig.toml
27+
package.json
2728
scripts
2829
- uses: ./.github/actions/node
2930
with:

.github/workflows/project.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@ jobs:
1515
steps:
1616
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
1717
with:
18-
sparse-checkout: .github
18+
sparse-checkout: |
19+
.github
20+
package.json
1921
- uses: ./.github/actions/node/latest
2022
- name: actionlint
2123
id: actionlint
@@ -82,6 +84,7 @@ jobs:
8284
with:
8385
sparse-checkout: |
8486
.github
87+
package.json
8588
scripts/verify-workflow-job-names.js
8689
- uses: ./.github/actions/node/latest
8790
- run: npm install yaml

.gitlab/prepare-oci-package.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@ bun=$(node -e "process.stdout.write(require('./scripts/bun').getBunBinary())")
1212
mkdir -p packaging/sources
1313

1414
tar -xOf "$archive" package/package.json > packaging/sources/package.json
15+
npm pkg delete scripts.prepare --prefix packaging/sources
1516
cp bun.lock packaging/sources/bun.lock
16-
"$bun" --config="$PWD/bunfig.toml" install --production --frozen-lockfile --ignore-scripts \
17+
"$bun" --config="$PWD/bunfig.toml" install --production --frozen-lockfile \
1718
--linker=hoisted --network-concurrency 8 --cwd packaging/sources
1819

1920
rm packaging/sources/package.json packaging/sources/bun.lock

LICENSE-3rdparty.csv

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
"component","origin","license","copyright"
2-
"@apm-js-collab/code-transformer","https://github.com/nodejs/orchestrion-js","['Apache-2.0']","['nodejs']"
3-
"@datadog/flagging-core","https://github.com/DataDog/openfeature-js-client","['Apache-2.0']","['DataDog']"
2+
"@apm-js-collab/code-transformer","https://github.com/nodejs/orchestrion-js","['Apache-2.0']","[]"
3+
"@datadog/flagging-core","https://github.com/DataDog/openfeature-js-client","['Apache-2.0']","[]"
44
"@datadog/libdatadog","https://github.com/DataDog/libdatadog-nodejs","['Apache-2.0']","['Datadog Inc.']"
55
"@datadog/native-appsec","https://github.com/DataDog/dd-native-appsec-js","['Apache-2.0']","['Datadog Inc.']"
66
"@datadog/native-iast-taint-tracking","https://github.com/DataDog/dd-native-iast-taint-tracking-js","['Apache-2.0']","['Datadog Inc.']"
77
"@datadog/native-metrics","https://github.com/DataDog/dd-native-metrics-js","['Apache-2.0']","['Datadog Inc.']"
8-
"@datadog/openfeature-node-server","https://github.com/DataDog/openfeature-js-client","['Apache-2.0']","['DataDog']"
8+
"@datadog/openfeature-node-server","https://github.com/DataDog/openfeature-js-client","['Apache-2.0']","[]"
99
"@datadog/pprof","https://github.com/DataDog/pprof-nodejs","['Apache-2.0']","['Google Inc.']"
10-
"@datadog/sketches-js","https://github.com/DataDog/sketches-js","['Apache-2.0']","['DataDog']"
10+
"@datadog/sketches-js","https://github.com/DataDog/sketches-js","['Apache-2.0']","[]"
1111
"@datadog/wasm-js-rewriter","https://github.com/DataDog/dd-wasm-js-rewriter","['Apache-2.0']","['Datadog Inc.']"
1212
"@emnapi/core","https://github.com/toyobayashi/emnapi","['MIT']","['toyobayashi']"
1313
"@emnapi/runtime","https://github.com/toyobayashi/emnapi","['MIT']","['toyobayashi']"
@@ -45,8 +45,8 @@
4545
"@oxc-parser/binding-win32-x64-msvc","https://github.com/oxc-project/oxc","['MIT']","['Boshen and oxc contributors']"
4646
"@oxc-project/types","https://github.com/oxc-project/oxc","['MIT']","['Boshen and oxc contributors']"
4747
"@tybys/wasm-util","https://github.com/toyobayashi/wasm-util","['MIT']","['toyobayashi']"
48-
"@types/estree","https://github.com/DefinitelyTyped/DefinitelyTyped","['MIT']","['DefinitelyTyped']"
49-
"argparse","https://github.com/nodeca/argparse","['Python-2.0']","['nodeca']"
48+
"@types/estree","https://github.com/DefinitelyTyped/DefinitelyTyped","['MIT']","['RReverser']"
49+
"argparse","https://github.com/nodeca/argparse","['Python-2.0']","[]"
5050
"astring","https://github.com/davidbonnet/astring","['MIT']","['David Bonnet']"
5151
"cjs-module-lexer","https://github.com/nodejs/cjs-module-lexer","['MIT']","['Guy Bedford']"
5252
"crypto-randomuuid","npm:crypto-randomuuid","['MIT']","['Stephen Belanger']"
@@ -56,24 +56,24 @@
5656
"es-module-lexer","https://github.com/guybedford/es-module-lexer","['MIT']","['Guy Bedford']"
5757
"escape-string-regexp","https://github.com/sindresorhus/escape-string-regexp","['MIT']","['Sindre Sorhus']"
5858
"esquery","https://github.com/estools/esquery","['BSD-3-Clause']","['Joel Feenstra']"
59-
"estraverse","https://github.com/estools/estraverse","['BSD-2-Clause']","['estools']"
59+
"estraverse","https://github.com/estools/estraverse","['BSD-2-Clause']","[]"
6060
"fast-fifo","https://github.com/mafintosh/fast-fifo","['MIT']","['Mathias Buus']"
6161
"import-in-the-middle","https://github.com/nodejs/import-in-the-middle","['Apache-2.0']","['Bryan English']"
6262
"istanbul-lib-coverage","https://github.com/istanbuljs/istanbuljs","['BSD-3-Clause']","['Krishnan Anantheswaran']"
63-
"jest-docblock","https://github.com/jestjs/jest","['MIT']","['jestjs']"
64-
"js-yaml","https://github.com/nodeca/js-yaml","['MIT']","['Vladimir Zapparov']"
63+
"jest-docblock","https://github.com/jestjs/jest","['MIT']","[]"
64+
"js-yaml","https://github.com/nodeca/js-yaml","['MIT']","['Vladimir Zapparov', 'Aleksey V Zapparov', 'Vitaly Puzrin', 'Martin Grenfell']"
6565
"jsep","https://github.com/EricSmekens/jsep","['MIT']","['Stephen Oney']"
66-
"jsonpath-plus","https://github.com/JSONPath-Plus/JSONPath","['MIT']","['Stefan Goessner']"
66+
"jsonpath-plus","https://github.com/s3u/JSONPath","['MIT']","['Stefan Goessner', 'Prof. Gössner', 'Subbu Allamaraju', 'Mike Brevoort', 'Robert Krahn', 'Brett Zamir', 'Richard Schneider']"
6767
"limiter","https://github.com/jhurliman/node-rate-limiter","['MIT']","['John Hurliman']"
68-
"lodash.sortby","https://github.com/lodash/lodash","['MIT']","['John-David Dalton']"
68+
"lodash.sortby","https://github.com/lodash/lodash","['MIT']","['John-David Dalton', 'Blaine Bublitz', 'Mathias Bynens']"
6969
"long","https://github.com/dcodeIO/long.js","['Apache-2.0']","['Daniel Wirtz']"
7070
"lru-cache","https://github.com/isaacs/node-lru-cache","['ISC']","['Isaac Z. Schlueter']"
71-
"meriyah","https://github.com/meriyah/meriyah","['ISC']","['Kenny F.']"
71+
"meriyah","https://github.com/meriyah/meriyah","['ISC']","['Kenny F.', 'Chunpeng Huo']"
7272
"module-details-from-path","https://github.com/watson/module-details-from-path","['MIT']","['Thomas Watson']"
7373
"mutexify","https://github.com/mafintosh/mutexify","['MIT']","['Mathias Buus']"
74-
"node-addon-api","https://github.com/nodejs/node-addon-api","['MIT']","['nodejs']"
74+
"node-addon-api","https://github.com/nodejs/node-addon-api","['MIT']","['Abhishek Kumar Singh', 'Alba Mendez', 'Alexander Floh', 'Ammar Faizi', 'András Timár, Dr', 'Andrew Petersen', 'Anisha Rohra', 'Anna Henningsen', 'Arnaud Botella', 'Arunesh Chandra', 'Azlan Mukhtar', 'Ben Berman', 'Benjamin Byholm', 'Bill Gallafent', 'blagoev', 'Bruce A. MacNaughton', 'Cory Mickelson', 'Daniel Bevenius', 'Dante Calderón', 'Darshan Sen', 'David Halls', 'Deepak Rajamohan', 'Dmitry Ashkadov', 'Dongjin Na', 'Doni Rubiagatra', 'Eric Bickle', 'extremeheat', 'Feng Yu', 'Ferdinand Holzer', 'Gabriel Schulhof', 'Guenter Sandner', 'Gus Caplan', 'Helio Frota', 'Hitesh Kanwathirtha', 'ikokostya', 'Jack Xia', 'Jake Barnes', 'Jake Yoon', 'Jason Ginchereau', 'Jenny', 'Jeroen Janssen', 'Jim Schlight', 'Jinho Bang', 'José Expósito', 'joshgarde', 'Julian Mesa', 'Kasumi Hanazuki', 'Kelvin', 'Kevin Eady', 'Kévin VOYER', 'kidneysolo', 'Koki Nishihara', 'Konstantin Tarkus', 'Kyle Farnung', 'Kyle Kovacs', 'legendecas', 'LongYinan', 'Lovell Fuller', 'Luciano Martorella', 'mastergberry', 'Mathias Küsel', 'Mathias Stearn', 'Matteo Collina', 'Michael Dawson', 'Michael Price', 'Michele Campus', 'Mikhail Cheshkov', 'nempoBu4', 'Nicola Del Gobbo', 'Nick Soggin', 'Nikolai Vavilov', 'Nurbol Alpysbayev', 'pacop', 'Peter Šándor', 'Philipp Renoth', 'rgerd', 'Richard Lau', 'Rolf Timmermans', 'Ross Weir', 'Ryuichi Okumura', 'Saint Gabriel', 'Sampson Gao', 'Sam Roberts', 'strager', 'Taylor Woll', 'Thomas Gentilhomme', 'Tim Rach', 'Tobias Nießen', 'todoroff', 'Toyo Li', 'Tux3', 'Vlad Velmisov', 'Vladimir Morozov', 'WenheLI', 'Xuguang Mei', 'Yohei Kishimoto', 'Yulong Wang', 'Ziqiu Zhao']"
7575
"node-gyp-build","https://github.com/prebuild/node-gyp-build","['MIT']","['Mathias Buus']"
76-
"opentracing","https://github.com/opentracing/opentracing-javascript","['Apache-2.0']","['opentracing']"
76+
"opentracing","https://github.com/opentracing/opentracing-javascript","['Apache-2.0']","[]"
7777
"oxc-parser","https://github.com/oxc-project/oxc","['MIT']","['Boshen and oxc contributors']"
7878
"pprof-format","https://github.com/DataDog/pprof-format","['MIT']","['Datadog Inc.']"
7979
"protobufjs","https://github.com/protobufjs/protobuf.js","['BSD-3-Clause']","['Daniel Wirtz']"
@@ -85,7 +85,7 @@
8585
"source-map","https://github.com/mozilla/source-map","['BSD-3-Clause']","['Nick Fitzgerald', 'Tobias Koppers', 'Duncan Beevers', 'Stephen Crane', 'Ryan Seddon', 'Miles Elam', 'Mihai Bazon', 'Michael Ficarra', 'Todd Wolfson', 'Alexander Solovyov', 'Felix Gnass', 'Conrad Irwin', 'usrbincc', 'David Glasser', 'Chase Douglas', 'Evan Wallace', 'Heather Arthur', 'Hugh Kennedy', 'Simon Lydell', 'Jmeas Smith', 'Michael Z Goddard', 'azu', 'John Gozde', 'Adam Kirkton', 'Chris Montgomery', 'J. Ryan Stinnett', 'Jack Herrington', 'Chris Truter', 'Daniel Espeset', 'Jamie Wong', 'Eddy Bruël', 'Hawken Rives', 'Gilad Peleg', 'djchie', 'Gary Ye', 'Nicolas Lalevée']"
8686
"spark-md5","https://github.com/satazor/js-spark-md5","['(WTFPL OR MIT)']","['André Cruz']"
8787
"tlhunter-sorted-set","https://github.com/tlhunter/node-sorted-set","['MIT']","['Thomas Hunter II']"
88-
"tslib","https://github.com/microsoft/tslib","['0BSD']","['Microsoft Corp.']"
88+
"tslib","https://github.com/Microsoft/tslib","['0BSD']","['Microsoft Corp.']"
8989
"ttl-set","https://github.com/watson/ttl-set","['MIT']","['Thomas Watson']"
9090
"aws-lambda-nodejs-runtime-interface-client","https://github.com/aws/aws-lambda-nodejs-runtime-interface-client/blob/v2.1.0/src/utils/UserFunction.ts","['Apache-2.0']","['Amazon.com Inc. or its affiliates']"
9191
"is-git-url","https://github.com/jonschlinkert/is-git-url/blob/396965ffabf2f46656c8af4c47bef1d69f09292e/index.js#L9C15-L9C87","['MIT']","['Jon Schlinkert']"

scripts/generate-3rdparty-licenses.js

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,7 @@ const FETCH_CONCURRENCY = 16
5454
*/
5555

5656
/**
57-
* @typedef {{
58-
* name: string,
59-
* versions?: Set<string>,
60-
* isRoot?: boolean
61-
* }} WantedComponent
57+
* @typedef {{ name: string, isRoot: true } | { name: string, versions: Set<string>, isRoot?: false }} WantedComponent
6258
*/
6359

6460
run().catch(error => {
@@ -196,8 +192,7 @@ async function fillMetadata (wanted, previous) {
196192
out.push({ component: entry.name, ...rootSelfMetadata() })
197193
continue
198194
}
199-
for (const version of entry.versions ?? []) {
200-
if (!version) throw new Error(`Cannot fetch exact npm metadata for ${entry.name} without a locked version`)
195+
for (const version of entry.versions) {
201196
toFetch.push({ name: entry.name, version })
202197
}
203198
}
@@ -226,12 +221,12 @@ async function fillMetadata (wanted, previous) {
226221
for (const license of packageLicenses) licenses.add(license)
227222
for (const owner of packageCopyright) copyright.add(owner)
228223
}
229-
const prev = previous.get(name)
224+
const previousOrigin = metadata.length > 1 ? previous.get(name)?.origin : undefined
230225
out.push({
231226
component: name,
232-
origin: prev?.origin ?? metadata[0].origin,
227+
origin: previousOrigin ?? metadata[0].origin,
233228
license: pythonList([...licenses]),
234-
copyright: prev && metadata.length === 1 ? prev.copyright : pythonList([...copyright]),
229+
copyright: pythonList([...copyright]),
235230
})
236231
}
237232

@@ -288,7 +283,9 @@ async function fetchPackageMetadata ({ name, version }) {
288283
function extractLicenses (data) {
289284
const licenses = []
290285
addLicense(data.license, licenses)
291-
for (const license of data.licenses ?? []) addLicense(license, licenses)
286+
if (data.licenses) {
287+
for (const license of data.licenses) addLicense(license, licenses)
288+
}
292289
return [...new Set(licenses)]
293290
}
294291

@@ -346,7 +343,8 @@ function extractCopyright (data) {
346343
const out = []
347344
const author = extractName(data.author)
348345
if (author) out.push(author)
349-
for (const contributor of data.contributors ?? []) {
346+
if (!data.contributors) return out
347+
for (const contributor of data.contributors) {
350348
const name = extractName(contributor)
351349
if (name) out.push(name)
352350
}

scripts/install_plugin_modules.js

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,7 @@ function invalidateCacheOnNodeAbiChange () {
9999
const versionsDir = join(__dirname, '..', 'versions')
100100
const nodeAbiFile = join(versionsDir, '.node-abi')
101101
const currentAbi = process.versions.modules
102-
let recordedAbi = ''
103-
try {
104-
recordedAbi = readFileSync(nodeAbiFile, 'utf8').trim()
105-
} catch {}
102+
const recordedAbi = existsSync(nodeAbiFile) ? readFileSync(nodeAbiFile, 'utf8').trim() : ''
106103
if (recordedAbi && recordedAbi !== currentAbi && existsSync(join(versionsDir, 'node_modules'))) {
107104
rmSync(join(versionsDir, 'node_modules'), { recursive: true, force: true })
108105
rmSync(join(versionsDir, 'bun.lock'), { force: true })
@@ -148,7 +145,8 @@ function buildInstallStages (packages) {
148145

149146
for (let index = 0; index < rangeStages.length; index++) {
150147
const stagedRanges = rangeStages[index].get(entry.name)
151-
for (const stagedRange of stagedRanges ?? []) {
148+
if (!stagedRanges) continue
149+
for (const stagedRange of stagedRanges) {
152150
if (semver.intersects(range, stagedRange)) {
153151
stageIndex = index + 1
154152
break
@@ -203,12 +201,19 @@ function applyExternalConfiguration (moduleNames, packages) {
203201
for (const { name } of packages) activeNames.add(name)
204202

205203
for (const name of activeNames) {
206-
for (const external of externals[name] ?? []) {
204+
const configurations = externals[name]
205+
if (!configurations) continue
206+
207+
for (const external of configurations) {
207208
if (external.dep) trustedDependencies.add(external.name)
208-
for (const trustedDependency of external.trustedDependencies ?? []) {
209-
trustedDependencies.add(trustedDependency)
209+
if (external.trustedDependencies) {
210+
for (const trustedDependency of external.trustedDependencies) {
211+
trustedDependencies.add(trustedDependency)
212+
}
210213
}
211-
for (const [dependency, version] of Object.entries(external.overrides ?? {})) {
214+
if (!external.overrides) continue
215+
216+
for (const [dependency, version] of Object.entries(external.overrides)) {
212217
// Bun only honours a bare package name. A Yarn-style selective path (`parent@1.0.0/child`) or an
213218
// npm-style nested object is accepted into the manifest and then silently ignored, so the range
214219
// reads as enforced while resolution stays untouched.

scripts/test/generate-3rdparty-licenses.spec.js

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ describe('scripts/generate-3rdparty-licenses.js', () => {
3636
},
3737
}))
3838
fs.writeFileSync(path.join(fixtureDirectory, 'bun.lock'), `{
39+
"lockfileVersion": 1,
3940
"workspaces": {
4041
"": {
4142
"dependencies": {
@@ -54,6 +55,7 @@ describe('scripts/generate-3rdparty-licenses.js', () => {
5455
}`)
5556
fs.writeFileSync(path.join(fixtureDirectory, 'vendor', 'package.json'), '{}')
5657
fs.writeFileSync(path.join(fixtureDirectory, 'vendor', 'bun.lock'), JSON.stringify({
58+
lockfileVersion: 1,
5759
workspaces: {
5860
'': {
5961
dependencies: {},
@@ -136,6 +138,30 @@ describe('scripts/generate-3rdparty-licenses.js', () => {
136138
)
137139
})
138140

141+
it('refreshes attribution metadata for a single locked version', async () => {
142+
fs.writeFileSync(path.join(fixtureDirectory, 'bun.lock'), JSON.stringify({
143+
lockfileVersion: 1,
144+
workspaces: { '': { dependencies: { foo: '2.0.0' } } },
145+
packages: { foo: ['foo@2.0.0', '', {}] },
146+
}))
147+
148+
await runGenerator({
149+
DD_TEST_LICENSE_METADATA: JSON.stringify({
150+
'2.0.0': {
151+
license: 'Apache-2.0',
152+
repository: 'https://new.example/repository',
153+
author: 'New author',
154+
},
155+
}),
156+
})
157+
158+
const generated = fs.readFileSync(path.join(fixtureDirectory, 'LICENSE-3rdparty.csv'), 'utf8')
159+
assert.match(
160+
generated,
161+
/"foo","https:\/\/new\.example\/repository","\['Apache-2\.0'\]","\['New author'\]"/
162+
)
163+
})
164+
139165
it('fails when a copied-source attribution names an installed dependency', async () => {
140166
fs.writeFileSync(
141167
path.join(fixtureDirectory, '.github', 'vendored-dependencies.csv'),
@@ -164,28 +190,9 @@ describe('scripts/generate-3rdparty-licenses.js', () => {
164190
assert.strictEqual(fs.readFileSync(csvPath, 'utf8'), before)
165191
})
166192

167-
it('fails when a lock entry has no exact registry version', async () => {
168-
fs.writeFileSync(path.join(fixtureDirectory, 'bun.lock'), `{
169-
"workspaces": {
170-
"": {
171-
"dependencies": {
172-
"foo": "file:../foo"
173-
}
174-
}
175-
},
176-
"packages": {
177-
"foo": ["foo", "", {}],
178-
},
179-
}`)
180-
181-
await assert.rejects(
182-
runGenerator({}),
183-
matchesMissingLockedVersion
184-
)
185-
})
186-
187193
/**
188-
* @param {NodeJS.ProcessEnv} env
194+
* @param {Record<string, string | undefined>} env
195+
* @returns {ReturnType<typeof execFileAsync>}
189196
*/
190197
function runGenerator (env) {
191198
const preloadPath = path.join(fixtureDirectory, 'registry-preload.js')
@@ -194,6 +201,7 @@ describe('scripts/generate-3rdparty-licenses.js', () => {
194201
env: {
195202
...process.env,
196203
...env,
204+
NODE_PATH: [path.join(repoRoot, 'node_modules'), process.env.NODE_PATH].filter(Boolean).join(path.delimiter),
197205
NODE_OPTIONS: `${process.env.NODE_OPTIONS ?? ''} --require=${preloadPath}`.trim(),
198206
},
199207
})
@@ -216,14 +224,6 @@ function matchesDuplicateAttribution (error) {
216224
return true
217225
}
218226

219-
/**
220-
* @param {Error & { stderr: string }} error
221-
*/
222-
function matchesMissingLockedVersion (error) {
223-
assert.match(error.stderr, /Cannot fetch exact npm metadata for foo without a locked version/)
224-
return true
225-
}
226-
227227
const registryPreload = String.raw`
228228
'use strict'
229229

scripts/test/install-plugin-modules.spec.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,9 @@ path.join = function join (...parts) {
298298
})
299299
})
300300

301+
/**
302+
* @returns {{ trustedDependencies: string[], overrides: Record<string, string> }}
303+
*/
301304
function readVersionsManifest () {
302305
return JSON.parse(fs.readFileSync(path.join(versionsDir, 'package.json'), 'utf8'))
303306
}
@@ -306,7 +309,7 @@ function readVersionsManifest () {
306309
* @param {string} plugin
307310
* @param {string} [binDirectory]
308311
* @param {string} [traceFile]
309-
* @param {NodeJS.ProcessEnv} [env]
312+
* @param {Record<string, string | undefined>} [env]
310313
* @returns {import('node:child_process').SpawnSyncReturns<string>}
311314
*/
312315
function runInstall (plugin, binDirectory, traceFile, env) {
@@ -327,7 +330,7 @@ function runInstall (plugin, binDirectory, traceFile, env) {
327330

328331
/**
329332
* @param {string} plugin
330-
* @param {NodeJS.ProcessEnv} [env]
333+
* @param {Record<string, string | undefined>} [env]
331334
* @returns {import('node:child_process').SpawnSyncReturns<string>}
332335
*/
333336
function spawnInstall (plugin, env = {}) {

0 commit comments

Comments
 (0)