Only create Cloudflare storage and D1 db spans when there is a parent span
Maintainers usually reply within 1 day
@nicohrubec is already working on this.
Since Oct 29, 2026.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 78/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- backend
Research direction
Read the five named instrumentation files and locate their startSpan calls. Add onlyIfParent: true to those calls, then inspect the existing Cloudflare instrumentation tests and add a test showing that an operation without an active span creates no span. Done when all five instrumentations skip creating spans without a parent and the test passes.
Written by the indexing model from the issue text.
Description
The Cloudflare D1, KV, Durable Object storage and SqlStorage instrumentations create db spans when there is no active span. Each of these spans becomes its own root span and has no context.
Pass onlyIfParent: true to the startSpan calls in:
packages/cloudflare/src/instrumentations/worker/instrumentD1.tspackages/cloudflare/src/instrumentations/worker/instrumentKV.tspackages/cloudflare/src/instrumentations/instrumentDurableObjectStorage.tspackages/cloudflare/src/instrumentations/instrumentDurableObjectSyncKvStorage.tspackages/cloudflare/src/instrumentations/instrumentSqlStorage.ts
Add a test that checks that an operation without an active span creates no span.
- Dominant language
- TypeScript
- Stars
- 8.8k
- Forks
- 1.9k
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 637
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from getsentry/sentry-javascript
-
Waiting for: Product Owner
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
getsentry/sentry-javascript#26203 · 1 comment ·
Maintainers usually reply within 1 day
-
Bug Node.js Waiting for: Product Owner
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
getsentry/sentry-javascript#26202 · 2 comments ·
Maintainers usually reply within 1 day
-
Workers AI integration drops output of non-streaming chat responses in the OpenAI format (`choices`)Possibly taken @andreiborza claimed this 2 days ago. OpenBug Cloudflare Workers Spans Waiting for: Product Owner
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
getsentry/sentry-javascript#26120 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
-
Only create Nuxt database and storage spans when there is a parent spanPossibly taken @nicohrubec claimed this 9 days ago. OpenImprovement Nuxt
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
getsentry/sentry-javascript#25805 · 3 comments ·
Maintainers usually reply within 1 day
-
Only create aws-sdk DynamoDB db spans when there is a parent spanPossibly taken @nicohrubec claimed this 9 days ago. OpenBug javascript
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
getsentry/sentry-javascript#25801 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
All issues in getsentry/sentry-javascript
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
bytedance/flowgram.ai#1235 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
devswha/herdr-web-ui#3325 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
desktop v3 windows
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
esengine/DeepSeek-Reasonix#15016 · 1 comment ·
Maintainers usually reply within 1 day