Consider dropping Bun 1.3 support in v12
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- bun, node.js, typescript
- Lĩnh vực
- backend, observability
Hướng nghiên cứu
Start with packages/bun/package.json and .github/workflows/build.yml to review the current Bun minimum and CI matrix. Then check the Bun integration test exclusions and vite.config.mts entries named in the issue. Done means the v12 minimum is Bun 1.4, CI no longer tests 1.3.14, and the Bun 1.3-specific exclusions are removed; this is proposed release policy work and may need maintainer agreement.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Bun 1.3.14 is the oldest Bun version that the SDK supports and tests in CI. On Bun 1.3, @sentry/bun does not instrument outgoing node:http requests. They get no sentry-trace or baggage headers and no spans, so traces break across services. Bun 1.4.0 and later work correctly.
We cannot fix this well on Bun 1.3. I suggest we drop Bun 1.3 in v12 and require Bun 1.4 or later.
Cause
- Bun 1.3 does not publish the
http.client.request.createddiagnostics channel. Bun 1.4.0 does. @sentry/nodedecides to use that channel fromprocess.versions.node. Bun 1.3.14 reports Node 24.3.0, so the SDK subscribes to a channel that never fires.- The fallback in
@sentry/core(client-patch.ts) wrapsClientRequest.prototype._storeHeader. Bun 1.3 uses anotherClientRequestimplementation that has no_storeHeader, so the fallback patches nothing.
Why a fix on Bun 1.3 is not practical
We tested these options on Bun 1.3.14:
- Wrap
ClientRequest.prototype.end: each request has its ownwriteandendmethods, so the request never calls the prototype hook. Also, a request with a streamed body sends its headers at the firstwrite(), beforeend(). - Wrap
http.requestandhttp.geton the module object: only code that calls through the default import orrequire('node:http')gets the wrapper. Named imports (import { request }) and namespace imports (import * as http) keep the original functions.http.getalso does not callhttp.requestinternally, so the wrapper must rewrite the request options before the call.
A fix would be a Bun-1.3-only rewrite of the request options. Named and namespace imports would still not work.
What changes if we drop Bun 1.3
- The minimum Bun version becomes 1.4:
engines.buninpackages/bun/package.json(now>=1.3.14) and the docs. - The CI matrix drops
1.3.14injob_bun_unit_testsandjob_bun_integration_tests(.github/workflows/build.yml). dev-packages/bun-integration-testscan remove the Bun < 1.4 excludes (BUN_BUILD_BEFORE_1_4_EXCLUDE,SENTRY_BUN_BEFORE_1_4_EXCLUDE) andBUN_BEFORE_1_4invite.config.mts. Those excludes also cover two other Bun 1.3 problems: CommonJS bundles oflangchainandlanggraphthrowrequire_ai is not a function, and theproxysuite fails in the@sentry/bunalias preload.
Until then
On Bun 1.3, express/with-http/base is excluded in the bun-build project (#26611). Users on Bun 1.3 who need trace propagation for outgoing node:http requests should upgrade to Bun 1.4 or later.
- Ngôn ngữ chính
- TypeScript
- Star
- 8.8k
- Fork
- 1.9k
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 744
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của getsentry/sentry-javascript
-
AWS Lambda Waiting for: Product Owner
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 82/100
getsentry/sentry-javascript#26910 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Only create Nuxt database and storage spans when there is a parent spanCó thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mởImprovement Nuxt
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
getsentry/sentry-javascript#25805 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Only create Cloudflare storage and D1 db spans when there is a parent spanCó thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mởCloudflare Workers Improvement Spans
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
getsentry/sentry-javascript#25804 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Core Feature: Typescript Meta: Breaking
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
getsentry/sentry-javascript#25286 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
javascript
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
getsentry/sentry-javascript#24200 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của getsentry/sentry-javascript
Issue tương tự
-
foreground-up-signals-live: delivery-repair cell expects a spawn suggestion status no longer printsĐang mởbug triage:owned
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
e2e-failure ready-to-code
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
redhat-developer/rhdh-plugin-export-overlays#4905 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
directus/directus#28558 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
review: medium
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
1lck/Lithe-IDEA#2432 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
cloudflare/workers-sdk#17189 ·
Maintainer thường phản hồi trong vòng 1 ngày