Repository navigation
Closed
Labels
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/node
SDK Version
8.9.1
Framework Version
Node 21.4.0
Link to Sentry event
No response
SDK Setup
No response
Steps to Reproduce
- Create a new project
npm init
- Install dependencies
npm i typescript @sentry/profiling-node
- Add a tsconfig.json
{
"compilerOptions": {
"strict": true
}
}- Create a file and import the module
import { nodeProfilingIntegration } from '@sentry/profiling-node';Expected Result
Types are found
Actual Result
Types are not found. Error message in VS Code:
Could not find a declaration file for module '@sentry/profiling-node'. '/Users/[redacted]/sentry-types/node_modules/@sentry/profiling-node/lib/cjs/index.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/sentry__profiling-node` if it exists or add a new declaration (.d.ts) file containing `declare module '@sentry/profiling-node';`
Looking at the package.json file in the module, it specifies lib/types/index.d.ts for the types:
{
...
"types": "lib/types/index.d.ts",
"exports": {
"./package.json": "./package.json",
".": {
"import": {
"types": "./lib/types/index.d.ts",
"default": "./lib/esm/index.js"
},
"require": {
"types": "./lib/types/index.d.ts",
"default": "./lib/cjs/index.js"
}
}
},
...
}However there is no file at that location.

Metadata
Metadata
Assignees
Labels
Projects
- StatusShow more project fieldsWaiting for: Product Owner
Activity
AbhiPrasad commentedon Jun 11, 2024
sorry for the trouble, I opened #12469 as a fix for this.
You can use
8.7.0for now to get around these problems, the regression was introduced with8.8.0and #12124fix(profiling): Update exports so types generate properly (#12469)
jstarmx commentedon Jun 12, 2024
Great, thanks very much @AbhiPrasad :)
andreiborza commentedon Jun 12, 2024
@jstarmx release
8.9.2is out now! Thank you again for reporting this.iscekic commentedon Jun 19, 2024
This is an issue again in
8.10.0AbhiPrasad commentedon Jun 19, 2024
Hi really sorry for the regression. I opened #12564 to fix, and #12565 to add an e2e test so we make sure these errors never happen again.
AbhiPrasad commentedon Jun 21, 2024
Released a fix with https://github.com/getsentry/sentry-javascript/releases/tag/8.11.0!