Skip to content

fix(cache): respect original h3's decoded path in swr handler - #4386

Merged
pi0 merged 1 commit into
nitrojs:v2from
Tofandel:patch-2
Jun 30, 2026
Merged

pi0 merged 1 commit into
nitrojs:v2from
Tofandel:patch-2

Conversation

@Tofandel

@Tofandel Tofandel commented Jun 26, 2026 •

Copy link
Copy Markdown

🔗 Linked issue

nuxt/nuxt#35447

❓ Type of change

  • 📖 Documentation (updates to the documentation, readme, or JSdoc annotations)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

We copy the original h3 event's path to the newly created event, as h3 internally in it's handlers decodes the req.url, but using createEvent does not do that, meaning the new event has an encoded url while the old event has a decoded url

📝 Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@Tofandel
Tofandel requested a review from pi0 as a code owner June 26, 2026 12:59
@vercel

vercel Bot commented Jun 26, 2026

Copy link
Copy Markdown

@Tofandel is attempting to deploy a commit to the Nitro Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 3d3ddc15-d7fe-454c-955b-e188448a1c25

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Tofandel Tofandel changed the title fix(cache): respect h3 url in swr handler fix(cache): respect original h3's decoded path in swr handler Jun 26, 2026
@pi0 pi0 added the v2 label Jun 30, 2026
@pkg-pr-new

pkg-pr-new Bot commented Jun 30, 2026

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/nitropack@4386

commit: a791d42

@pi0
pi0 merged commit 795a887 into nitrojs:v2 Jun 30, 2026
9 of 13 checks passed
@Tofandel

Tofandel commented Jul 8, 2026

Copy link
Copy Markdown
Author

What's the release schedule of nitro like for v2? When can I expect a release, to know if I should wait or if I need to do a patch package?

@letoast

letoast commented Sep 11, 2026

Copy link
Copy Markdown

Hi @pi0 any release schedule for v2? Double url encoding is causing quite a headache with some urls :/

@pi0x pi0x removed the v2 label Nov 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants