Follow up to #24343
With build-time instrumentation, @sentry/solidstart force-inlines mysql and ioredis into the Nitro server bundle, but their CommonJS dependencies stay external. Rollup reads those external dependencies through getDefaultExportFromNamespaceIfNotNamed, which only unwraps default when it is the only key on the namespace. From Node 24.0, a CommonJS namespace also has a module.exports key, so the helper returns the namespace object and the drivers break at runtime:
mysql: TypeError: SqlString.format is not a function
ioredis: TypeError: (0 , lodash_1.defaults) is not a function
This is not specific to CI, every SolidStart app with mysql or ioredis on Node 24+ is affected. The same built server fails without the Sentry --import hook, so the problem is in the bundle output, not in the runtime SDK.
| Node |
Result |
| 20.19.5, 22.22.3 |
works |
| 24.0.0 to 24.21.0, 26.1.0 |
fails |
External CommonJS dependencies in a SolidStart build that have only default and module.exports on Node 24: bignumber.js, sqlstring (from mysql), denque, lodash.defaults, lodash.isarguments (from ioredis). Other instrumented modules can have more. @rollup/plugin-commonjs 29.0.3 still ships the same helper.
@sentry/nuxt builds the same inline list in packages/nuxt/src/vite/orchestrion.ts. I did not verify whether Nuxt apps are affected.
Possible fixes:
- Add the dependencies above to the inline list next to
standard-as-callback in packages/solidstart/src/config/withSentry.ts (and in Nuxt, if affected). Small, but covers only the known modules.
- Fix the interop for all external dependencies of inlined modules in
sentryOrchestrionPlugin, for example with @rollup/plugin-commonjs options.
When this is fixed, remove the volta.node pin (20.19.5) from the solidstart and solidstart-static E2E apps, which #24343 added so their E2E tests keep running on Node 20.
Follow up to #24343
With build-time instrumentation,
@sentry/solidstartforce-inlinesmysqlandioredisinto the Nitro server bundle, but their CommonJS dependencies stay external. Rollup reads those external dependencies throughgetDefaultExportFromNamespaceIfNotNamed, which only unwrapsdefaultwhen it is the only key on the namespace. From Node 24.0, a CommonJS namespace also has amodule.exportskey, so the helper returns the namespace object and the drivers break at runtime:mysql:TypeError: SqlString.format is not a functionioredis:TypeError: (0 , lodash_1.defaults) is not a functionThis is not specific to CI, every SolidStart app with
mysqlorioredison Node 24+ is affected. The same built server fails without the Sentry--importhook, so the problem is in the bundle output, not in the runtime SDK.External CommonJS dependencies in a SolidStart build that have only
defaultandmodule.exportson Node 24:bignumber.js,sqlstring(frommysql),denque,lodash.defaults,lodash.isarguments(fromioredis). Other instrumented modules can have more.@rollup/plugin-commonjs29.0.3 still ships the same helper.@sentry/nuxtbuilds the same inline list inpackages/nuxt/src/vite/orchestrion.ts. I did not verify whether Nuxt apps are affected.Possible fixes:
standard-as-callbackinpackages/solidstart/src/config/withSentry.ts(and in Nuxt, if affected). Small, but covers only the known modules.sentryOrchestrionPlugin, for example with@rollup/plugin-commonjsoptions.When this is fixed, remove the
volta.nodepin (20.19.5) from thesolidstartandsolidstart-staticE2E apps, which #24343 added so their E2E tests keep running on Node 20.