Closed notaphplover closed 7 months ago
I run into this same exact error as well. It's a bummer for my company because the profiling feature in Grafana looks great, but until this is fixed, my company cannot integration with pyroscope for our NodeJS typescript applications
Thank you @notaphplover for the well described issue and sorry for the delay. Please see https://github.com/grafana/pyroscope-nodejs/pull/42
You're very welcome @kolesnikovae , have you tested the artifact? I would hazard to say the package.json
should be updated removing the types
property. Otherwise types won't be correctly applied
Edit: It seems it's working :smile:
Thank you @notaphplover, I'm glad to hear this. I've tested the artifact with the tool you suggested (super handy!) and also in a simple test program. I think you're right – the "types" directive is not used anymore – I'll take care of it
Description
I cannot easily access types from the package in order to use it in my ts codebase.
Reproduction of the issue
typescript@5
and@pyroscope/nodejs@0.2.6
dependencies.src/index.ts
source file:Expected behavior
Actual behavior:
Additional context.
types
folder in the@pyroscope/nodejs
package. Thebuild:cjs
andbuild:esm
npm scripts should emit declaration files, you can achieve this with the"declaration": true,
option enabled in their associatedtsconfig
files.build:types
is no longer necessary, it adds unreached types to the package.Consider this tool when solving this issue, it allows you to upload the artifact generated by the
npm pack
script in order to analyze it.