Skip to content

Interest in integrating the sphinx-paramlinks extension #11456

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

Open
CaselIT opened this issue Jun 7, 2023 · 4 comments
Open

Interest in integrating the sphinx-paramlinks extension #11456

CaselIT opened this issue Jun 7, 2023 · 4 comments

Comments

@CaselIT
Copy link

CaselIT commented Jun 7, 2023

Hello

I've opened this issue to ask if there is interest in integrating the features of the https://github.com/sqlalchemyorg/sphinx-paramlinks extension.

The main feature of this extension are, like mentioned in its readme, to allow link to function and method params and cross-link to them.

A live example is in the sqlalchemy does. For example this is a link to a function param, and in the parameter description there is a cross-link the another function parameter (create_engine.echo).
The python source for that part is this https://github.com/sqlalchemy/sqlalchemy/blob/5f26a66aeca841ca2ec714d3473394d61a29ed9a/lib/sqlalchemy/engine/base.py#L302-L310

I've never contributed to sphinx, but if there is interest in this feature I can work to create an PR to upstream it.
I've asked the creator of the extension, @zzzeek, and he's ok with it.

@picnixz
Copy link
Member

picnixz commented Jul 13, 2023

I am in favor of this addition, but the decision is left to the maintainers @AA-Turner (and maybe @tk0miya).

An alternative worth to consider is incorporating this mechanism directly at the role level instead (when parsing :param:) and having a simple boolean enabling the creation of a reference node.

@electric-coder
Copy link

electric-coder commented Jul 18, 2023

As a user, I think this is a highly desirable feature since there's no way to write cross-references to parameters using only sphinx.ext and Sphinx core. (I don't have a workaround and my alternative has been to mention parameters in prose with double backticks to at least get them highlighted.)

The only reason I haven't adopted sphinx.paramlinks is to avoid adding another 3rd party dependency to my projects.

The only problem is, afaict, that the Sphinx project itself doesn't seem to currently have enough volunteers to keep up with the growing backlog of maintenance issues. (And it remains to be seen if Sphinx will be able to continue supporting major changes to the typing module...)

@electric-coder
Copy link

electric-coder commented Jul 27, 2023

Related, one of the oldest open Sphinx issues: #538.

@CaselIT
Copy link
Author

CaselIT commented Jul 28, 2023

Did not know about that issue. I'll post a link to this issue there

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

4 participants