Skip to content
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

linkcheck should check URLs of raw directives #10755

Closed
n-peugnet opened this issue Aug 6, 2022 · 4 comments · Fixed by #10757
Closed

linkcheck should check URLs of raw directives #10755

n-peugnet opened this issue Aug 6, 2022 · 4 comments · Fixed by #10757
Labels
builder:linkcheck type:enhancement enhance or introduce a new feature

Comments

@n-peugnet
Copy link
Contributor

Is your feature request related to a problem? Please describe.
When using a raw directive with the url option, the linkcheck builder does not check this URL.

Describe the solution you'd like
I would expect the URLs of raw directives to be checked by linkcheck.

@n-peugnet n-peugnet added the type:enhancement enhance or introduce a new feature label Aug 6, 2022
@n-peugnet
Copy link
Contributor Author

Sorry I just found out that Sphinx resolves raw directives while reading sources so an error will be displayed before the linkcheck builder is even used.

@n-peugnet
Copy link
Contributor Author

On second thought it could still be useful to check for redirections.

@francoisfreitag
Copy link
Contributor

So the suggestion is that linkcheck fails if a raw directive url attribute points to a server that issues a redirect outside of https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-linkcheck_allowed_redirects?

@n-peugnet
Copy link
Contributor Author

Yes, I implemented (and tested) it in #10757.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
builder:linkcheck type:enhancement enhance or introduce a new feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants