cloudflare / cloudflare/vinext

Middleware does not run for static-asset requests covered by its matcher

Open
#3,217 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
8.8k
Forks
406
Avg merge
2d 6h
Merged PRs (30d)
120

Description

_Found running the official Next.js e2e test suite against vinext (vinext 1.0.0-beta.8, Next.js 16.2). Error line is from the suite's own output._

**Fixture:** `test/e2e/middleware-static-files`

**Symptom:** a `.svg` under the middleware matcher is served directly and middleware never executes, so the expected response marker (`{ middleware: true }`) is absent.

**Repro:** a matcher that includes a static path; request that path and assert middleware ran.

Contributor guide

Open the contributing guide

Research direction

Start with the `test/e2e/middleware-static-files` fixture and the request path used by the official Next.js e2e test suite. Reproduce a request for the matched `.svg` and trace why the static asset is served without middleware execution. Done means the response includes the expected `{ middleware: true }` marker for a static path covered by the matcher.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
74/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.