[DOCS] documentation site 'Edit On GitHub' links return a 404
wesdevpro opened this issue · comments
Discussed in #2859
Originally posted by benhopkinstech January 22, 2024
Hello all,
Sorry if this is the wrong means of doing this but I don't feel it warranted an issue being created due to it not being a problem with the code itself.
When I was browsing the documentation website I noticed that the 'Edit on GitHub' links all seem to return a 404.
The links seem to point to the repository on the master
branch which must have existed previously before being renamed to main
.
For example https://github.com/octokit/octokit.net/edit/master/docs/index.md is the link provided when trying to edit the home page.
This should read https://github.com/octokit/octokit.net/edit/main/docs/index.md.
Hopefully it should just be a matter of updating the base url on the documentation site to https://github.com/octokit/octokit.net/edit/main/docs/.
Ben
@benhopkinstech would you prefer to have the conversation here or in the discussion you created?
@kfcampbell just keep it here and close the discussion, I wasn't sure where to raise it initially as I know the site is external to the repository.
I've done so! I'm also going to copy my initial response there to here:
What's really curious to me is that in most cases, such as clicking on the "Getting Started" guide here, GitHub will redirect to the correct branch and show a little banner:
As for actually fixing this, I'm struggling to find where to make the change. I'm not seeing any relevant configuration in our docs configuration in mkdocs.yml
. Searching for "master" in our codebase doesn't lead anywhere that looks useful (though incidentally I created this PR to correct some links using it when they shouldn't be). I wonder if readthedocs.io assumes our default branch incorrectly?
I've requested approval on that PR.
It still doesn't answer the issue on the readthedocs site, I have found this issue.
Looks like we will need whoever has an account for the site to go in and change the settings.
Ooh that's interesting... @nickfloyd do you know who might own those credentials? I've checked and I don't have access to anything that looks relevant.
Sign in should be available here