Skip to content

Extra slash in "Edit on GitHub" link #5303

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

Closed
mahmoud opened this issue Feb 18, 2019 · 9 comments
Closed

Extra slash in "Edit on GitHub" link #5303

mahmoud opened this issue Feb 18, 2019 · 9 comments

Comments

@mahmoud
Copy link

mahmoud commented Feb 18, 2019

Details

Expected Result

"Edit on GitHub" link at the top of the page should link to doc on GitHub.

Actual Result

"Edit on GitHub" link at the top of the page links to 404. There is an extra slash in the URL: https://github.com/mahmoud/glom//master/docs/index.rst (after glom, before master)

Interestingly, the "Edit" link in the bottom left menu seems to work fine.

@csranasinghe
Copy link
Contributor

csranasinghe commented Feb 18, 2019

Hi @mahmoud ,
I don't think it happens because of the extra slash but because of the missing word blob. The url should be https://github.com/mahmoud/glom/blob/master/docs/index.rst. Isn't it?

@stsewd
Copy link
Member

stsewd commented Feb 18, 2019

@stsewd stsewd added the Needed: more information A reply from issue author is required label Feb 18, 2019
@mahmoud
Copy link
Author

mahmoud commented Feb 18, 2019

@rexzing you're absolutely right!

@stsewd trying this now, thanks!

@no-response no-response bot removed the Needed: more information A reply from issue author is required label Feb 18, 2019
@mahmoud
Copy link
Author

mahmoud commented Feb 18, 2019

@stsewd Hmm, no luck I'm afraid. In fact, I see 3 slashes now: https://github.com/mahmoud/glom///master/docs/index.rst.

@stsewd
Copy link
Member

stsewd commented Feb 18, 2019

Thanks, I'll try to replicate this locally and dig a little more

@mahmoud
Copy link
Author

mahmoud commented Feb 18, 2019

Whoops, I lied, did stuff on the wrong local branch. Updating the theme got me a working link, with blob, but it does have an extra slash fwiw: https://github.com/mahmoud/glom//blob/master/docs/index.rst

It still gets me to GitHub though, so I'm happy enough! :) Thanks for your help!

@stsewd
Copy link
Member

stsewd commented Feb 19, 2019

The extra slash is from the repo url, we could strip it, tho

@mahmoud
Copy link
Author

mahmoud commented Feb 19, 2019

I'll leave it up to you, but I think an rstrip and join of a single slash should yield a nicely normalized URL. :)

stsewd added a commit to stsewd/readthedocs.org that referenced this issue Feb 19, 2019
@mahmoud
Copy link
Author

mahmoud commented Feb 19, 2019

@stsewd Thank you!

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

No branches or pull requests

3 participants