New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unhandled runtime error originated from Invalid URL using i18n #23772
Labels
bug
Issue was opened via the bug report template.
Comments
That is indeed weird 🤔 |
Seems like an easy fix but I'm not familiar with nextjs codebase. |
Hey @timneutkens, I don't know if this is urgent or not, but my guess is that it is since it breaks the app. |
danielsimao
changed the title
Unhandled runtime error originated from Invalid URL when using i18n
Unhandled runtime error originated from Invalid URL using i18n
Jun 2, 2021
danielsimao
added a commit
to danielsimao/next.js
that referenced
this issue
Jun 3, 2021
kodiakhq bot
pushed a commit
that referenced
this issue
Aug 3, 2021
This adds handling for repeated forward/back slashes in Next.js, when these slashes are detected in a request to Next.js we will automatically remove the additional slashes redirecting with a 308 status code which prevents duplicate content when being crawled by search engines. Fixes: #13011 Fixes: #23772 Closes: #15171 Closes: #25745
flybayer
pushed a commit
to blitz-js/next.js
that referenced
this issue
Aug 19, 2021
This adds handling for repeated forward/back slashes in Next.js, when these slashes are detected in a request to Next.js we will automatically remove the additional slashes redirecting with a 308 status code which prevents duplicate content when being crawled by search engines. Fixes: vercel#13011 Fixes: vercel#23772 Closes: vercel#15171 Closes: vercel#25745
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
What version of Next.js are you using?
10.1.3
What version of Node.js are you using?
12.16
What browser are you using?
Chrome
What operating system are you using?
macOS
How are you deploying your application?
next start
Describe the Bug
In the root of the application, adding 2 slashes ("//"), generates a unhandled run time error and ends up not rendering the 404 page. This only starts occurring when i18n is added in next.config.js.
❌ https://ngyzq.sse.codesandbox.io// - breaks in base path
✅ https://ngyzq.sse.codesandbox.io/about// - handled correctly with 404 rendered in subpaths
Expected Behavior
Should handle invalid URL with 404 page.
To Reproduce
https://codesandbox.io/s/modern-sea-ngyzq?file=/next.config.js
The text was updated successfully, but these errors were encountered: