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
Existing use of Hugo aliases risks overlap and redirects going to wrong page #46295
Comments
/triage accepted |
Thanks for raising this issue, @enj! Since we don't have any linting at the moment, I think it would be reasonable to find other similar cases where we might benefit. If we make a more extensive list, we'll better understand what is needed in the end, yet we can still start from the most essential cases. Here are a few examples that come to my mind based on my experience in localisation:
|
This issue suggests a particular fix (and not the one I'd pick). @enj if you're willing to pick a different issue title, please do. The problem is that aliases can overlap silently, and this can break existing redirects. It's easy for a localization team to miss that they've done this. How I'd solve it: build the Likely outcomes for the approach I advocate:
I've seen this done by other Hugo sites that use Netlify, so it's new ground but new-for-SIG-Docs not new-for-the-world. We can borrow ideas from existing open source docs sites and wouldn't have to invent a new thing from scratch. |
/priority important-longterm |
_redirects
file
@sftim I took a shot at updating the title of the issue, please feel free to edit. |
/retitle Existing use of Hugo aliases risks overlap and redirects going to wrong page |
_redirects
file
A change made in #43368 broke the https://kubernetes.io/security and other aliases because it also set them for the RU pages. This should ideally fail in CI and during local dev, as it is an easy mistake to make, and difficult to catch during code review.
Originally posted by @enj in #46281 (comment)
The text was updated successfully, but these errors were encountered: