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

Default sphinx role "autolink" appears to be deprecated #18879

Open
timhoffm opened this issue Apr 30, 2021 · 2 comments
Open

Default sphinx role "autolink" appears to be deprecated #18879

timhoffm opened this issue Apr 30, 2021 · 2 comments

Comments

@timhoffm
Copy link
Contributor

I noticed that numpy uses a shpinx config setting

default_role = "autolink"

This is poor documented at sphinx, but seems to be deprecated:
https://www.sphinx-doc.org/en/master/search.html?q=autolink

and is scheduled for removal in Sphinx 4.0.

@ghost
Copy link

ghost commented May 16, 2021

Hi Tim,
According to this discussion on scikit-learn, I think it better to change autolink to another value, like any, so default_role can become more useful.

@timhoffm
Copy link
Contributor Author

I agree that the default role needs changing (if only for the fact that "autolink" seems deprecated). At Matplotlib, we use obj, which is a bit more restrictive than any. Most things we link are other classes/functions. Also trying to catch ref, doc and option seemed a little too ambitious; but YMMV.

Note that when changing to any or obj, you'll get warnings for the current numpydoc style which uses the default role for parameters (see numpy/numpydoc#323). That would have to be addressed one way or the other.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant