We're getting this warning in tests:
Since Acorn 8.0.0, options.ecmaVersion is required.
Defaulting to 2020, but this will stop working in the future.
Need:
diff --git a/packages/trace-deps/lib/trace.js b/packages/trace-deps/lib/trace.js
index bce66bd..5a96095 100644
--- a/packages/trace-deps/lib/trace.js
+++ b/packages/trace-deps/lib/trace.js
@@ -543,7 +543,7 @@ const traceFile = async ({
} catch (modErr) {
// Then as script.
try {
- ast = parse(src, { sourceType: "script", locations: true, onComment });
+ ast = parse(src, { sourceType: "script", ecmaVersion: "latest", locations: true, onComment });
} catch (scriptErr) {
// Use original module error, with some helper errors.
throw new Error(`Encountered parse error in ${srcPath}: ${modErr}`);
We're getting this warning in tests:
Need: