swc-plugin-coverage-instrument icon indicating copy to clipboard operation
swc-plugin-coverage-instrument copied to clipboard

Segmentation Fault when using Nextjs 14

Open jwickens opened this issue 9 months ago • 3 comments

With next 14.2.5 (I also tested with 14.2.25) using next dev results in the process silently failing and with next build a "Segmentation Fault" is printed out.

Of the plugin I tried versions 0.0.26 then each minor down to 0.0.22.

I tried integrating with both .swrc and in next.config.js:

if (process.env.COVERAGE === 'true') {
  nextConfig.experimental.swcPlugins = [['swc-plugin-coverage-instrument', {}]];
} 
> COVERAGE=true npm run build
[...]
  ▲ Next.js 14.2.24
  - Environments: .env.local, .env
  - Experiments (use with caution):
    · swcPlugins
    · scrollRestoration
[...]
 ✓ Linting and checking validity of types
   Creating an optimized production build ...
Segmentation fault (core dumped)

jwickens avatar Mar 03 '25 13:03 jwickens