feat(node): Bump to latest @fastify/otel#19452
Conversation
This PR unvendors `@fastify/otel` and bumps to the latest version. We can do this now because the newest `minimatch` expanded node support to node 18. Closes: #19450
size-limit report 📦
|
node-overhead report 🧳Note: This is a synthetic benchmark with a minimal express app and does not necessarily reflect the real-world performance impact in an application.
|
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
- Cast instrumentFastify return type to prevent @fastify/otel types from leaking into the public API (fixes TS 3.8 and TS 5.0 compatibility) - Remove `service.name` span assertions no longer emitted by @fastify/otel@0.16.0 - Bump @sentry/node size limit from 167KB to 171KB
| resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" | ||
| integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== | ||
|
|
||
| balanced-match@^4.0.2: | ||
| version "4.0.3" | ||
| resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-4.0.3.tgz#6337a2f23e0604a30481423432f99eac603599f9" | ||
| integrity sha512-1pHv8LX9CpKut1Zp4EXey7Z8OfH11ONNH6Dhi2WDUt31VVZFXZzKwXcysBgqSumFCmR+0dqjMK5v5JiFHzi0+g== | ||
|
|
||
| bare-events@^2.2.0, bare-events@^2.5.4: | ||
| version "2.5.4" | ||
| resolved "https://registry.yarnpkg.com/bare-events/-/bare-events-2.5.4.tgz#16143d435e1ed9eafd1ab85f12b89b3357a41745" |
There was a problem hiding this comment.
Bug: The new @fastify/otel dependency transitively adds minimatch@10, which requires Node.js 20+, but @sentry/node supports Node.js 18+, causing a version incompatibility.
Severity: HIGH
Suggested Fix
To resolve the Node.js engine incompatibility, consider using a resolutions field in package.json to force minimatch to a version compatible with Node.js 18, such as the latest v9 release. Alternatively, investigate if @fastify/otel can be configured to use a compatible version or if there is a patch release that addresses this issue. If not, the @sentry/node package's supported Node.js version may need to be updated to "node": ">=20".
Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: yarn.lock#L12491-L12501
Potential issue: The update to `@fastify/otel@0.16.0` introduces a transitive dependency
on `minimatch@^10.0.3`, which requires Node.js version 20 or higher. However, the
`@sentry/node` package's `engines` field specifies support for Node.js version 18 and
up. This creates a direct incompatibility. Users running `@sentry/node` on Node.js 18 or
19 will install the incompatible `minimatch` version. This can lead to runtime errors
when the Fastify instrumentation is active, as `@fastify/otel` uses `minimatch` to
process its `ignorePaths` configuration.
Did we get this right? 👍 / 👎 to inform future reviews.
|
Drafting this because transitive deps require node 20 :'( |
This PR unvendors
@fastify/oteland bumps to the latest version. We can do this now because the newestminimatchexpanded node support to node 18.Closes: #19450