Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sentry-prune-profiler-binaries does not recognize NodeJS 22 as a valid major node version #14488

Open
3 tasks done
Jimmy89 opened this issue Nov 26, 2024 · 0 comments · May be fixed by #14491
Open
3 tasks done

sentry-prune-profiler-binaries does not recognize NodeJS 22 as a valid major node version #14488

Jimmy89 opened this issue Nov 26, 2024 · 0 comments · May be fixed by #14491
Labels
Package: profiling-node Issues related to the Sentry Profiling Node SDK

Comments

@Jimmy89
Copy link

Jimmy89 commented Nov 26, 2024

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/aws-serverless

SDK Version

8.40.0

Framework Version

NodeJS v22

Link to Sentry event

No response

Reproduction Example/SDK Setup

My package.json dependencies:

    "@sentry/aws-serverless": "^8.40.0",
    "@sentry/profiling-node": "^8.40.0",

As part of my webpack build for my lambda I copy the sentry profile binaries from the Sentry node package ('./node_modules/@sentry/profiling-node/lib/sentry_cpu_profiler-*.node') and strip them with the command:

node_modules/.bin/sentry-prune-profiler-binaries --target_dir_path=./dist/lambda/sentry --target_platform=linux --target_node=22 --target_stdlib=glibc --target_arch=x64

This command used to be --target_node=20, but with AWS Lambda supporting v22 I changed it to v22.

However, the command gives as output:
❌ Sentry: Invalid node version passed as argument, please make sure --target_node is a valid major node version. Supported versions are 16, 18 and 20.

As NodeJS become LTS last month, I was expecting the pruner to have support for this. Hopefully it is only a matter of adding the integer to the code.

I found the check to reside here:

Steps to Reproduce

  1. Run yarn install with the example dependencies.
  2. Copy the sentry_cpu_profiles nodes to the destination folder.
  3. Running the sentry prune script.

Expected Result

One left-over files from the prune list, without error.

Actual Result

Error not supporting NodeJS v22

@getsantry getsantry bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 3 Nov 26, 2024
@github-actions github-actions bot added the Package: aws-serverless Issues related to the Sentry AWS Serverless SDK label Nov 26, 2024
@chargome chargome added Package: profiling-node Issues related to the Sentry Profiling Node SDK and removed Package: aws-serverless Issues related to the Sentry AWS Serverless SDK labels Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: profiling-node Issues related to the Sentry Profiling Node SDK
Projects
Status: Waiting for: Product Owner
Development

Successfully merging a pull request may close this issue.

2 participants