Skip to content

Commit

Permalink
fix(v8): remove trace_event starting with 12.6 (#807)
Browse files Browse the repository at this point in the history
Also add a custom error message when a dependency disappears to avoid
the unhelpful `Cannot read properties of undefined (reading 'split')`.

Refs: v8/v8@f8fa220
  • Loading branch information
targos committed May 11, 2024
1 parent 39f1002 commit b30988a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/update-v8/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ export const v8Deps = [
match: '/base\n',
replace: ''
},
since: 55
since: 55,
until: 125
},
{
name: 'gtest',
Expand Down
3 changes: 3 additions & 0 deletions lib/update-v8/majorUpdate.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,9 @@ async function readDeps(nodeDir, depName) {
let deps;
eval(depsDeclaration); // eslint-disable-line no-eval
const dep = deps[depName];
if (!dep) {
throw new Error(`V8 dep "${depName}" not found in DEPS file`);
}
if (typeof dep === 'object') {
return dep.url.split('@');
}
Expand Down

0 comments on commit b30988a

Please sign in to comment.