GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [nextjs] Tunnel route requests are not dropped under the `Next.request` root span (Next.js 16.4.3+) · Issue #26093 · getsentry/sentry-javascript

[nextjs] Tunnel route requests are not dropped under the Next.request root span (Next.js 16.4.3+) #26093

New issue
Copy link
New issue
Copy link
Closed
Closed
[nextjs] Tunnel route requests are not dropped under the Next.request root span (Next.js 16.4.3+)#26093
Copy link
Assignees
chargome
Labels
BugNext.js

Description

@chargome
chargome
opened on Nov 4, 2026
Issue body actions

Follow-up to #26005 (#26005).

Since Next.js 16.4.3, a proxy that runs separately from the render (for example on Vercel) gets a new Next.request root span. Middleware.execute becomes its child.

Our tunnel filter only looks at Middleware.execute and BaseServer.handleRequest spans. So for tunnel requests that go through the proxy, only the child span gets dropped. The Next.request root is still sent as a GET transaction (subject to the sample rate). This is noise, not a loop, because the server SDK sends straight to the DSN.

Affected code:

  • dropMiddlewareTunnelRequests() in packages/nextjs/src/common/utils/dropMiddlewareTunnelRequests.ts (the drop flag)
  • getTunnelRouteIgnoreSpans() in the same file (the ignoreSpans pattern used with span streaming)

vercel/next.js#100665 makes Middleware.execute the root again for requests the proxy answers itself. Requests that continue to a render keep the Next.request root, so we need the fix either way.

Related, possibly in the same PR: the Next.request root also gets the wrong name and op (GET middleware GET / http.server on Node, GET with no op on Edge). Before 16.4.3 these were middleware GET / http.server.middleware.

The nextjs-16-adapter e2e app from #26084 calls the proxy the way Vercel does, so it can cover this.

Activity

  1. chargome
    self-assigned this
    on Nov 4, 2026
  2. chargome
    added
    Bug
    on Nov 4, 2026
  3. linear-code commented on Nov 4, 2026

    @linear-code
    linear-codeBot
    on Nov 4, 2026 – with Linear Code
    More actions

    JS-4064

  4. chargome
    added
    Next.js
    on Nov 4, 2026
  5. chargome
    closed this as completedon Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @chargome
    chargome

Labels

BugNext.js

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.