getsentry / getsentry/sentry-javascript

Sentry can't instument express if it is bundled

Đang mở
#15,017 3 bình luận 0 reaction 0 người được giao Xem trên GitHub
Improvement Node.js
Ngôn ngữ chính
TypeScript
Star
8.7k
Fork
1.8k
Merge trung bình
1 ngày 17 giờ
Pull request đã merge (30 ngày)
523

Mô tả

### Is there an existing issue for this?

- [x] I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- [x] I have reviewed the documentation https://docs.sentry.io/
- [x] 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.48.0

### Framework Version

Express 4.21.2

### Link to Sentry event

_No response_

### Reproduction Example/SDK Setup

_No response_

### Steps to Reproduce

Use sentry for node in an angular ssr appllication that is based on express.

### Expected Result

Sentry can instrument express

### Actual Result

Sentry comlains that express is not instrumented even through the instrument file was preloaded with `--import`.

My guess is that since angular bundles express into the server, sentry misses out on the import that it tries to wrap, leading to it not instrumenting express. I would be thankful for some ideas on how this could be improved.
Also if it is just adding a bunch of middlewares and such

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.