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
autodoc: Extract docstring, leave the signature up to me #963
Comments
From Michael Elsdörfer on 2012-07-08 16:36:51+00:00 FWIW, after spending some time reading the code, I now understand that the thing that I return from my autodoc-process-signature handler is inserted verbatim into a :py:data: directive; as a result of which, it will no longer be associated with the property in the index, if I put custom stuff in there. What is happening is quite opaque if one doesn't know what is going on behind the scenes. I have no solved this for me by implementing a custom Documenter class, though I still would like to see this improved. In particular, I'm still unable to get rid of the module prefix. That is, what is generated is: {{{ and what I would like is: {{{ |
From Jon Waltman on 2012-09-21 00:55:04+00:00 The configuration variable [[http://sphinx.pocoo.org/config.html?highlight=add_module_names#confval-add_module_names|add_module_names]] can be used to control whether or not the current module name is appended to each description. You can try it out by adding this in your conf.py: {{{ Does this do what you want? |
From Johannes Dewender on 2013-01-21 16:46:31+00:00 I am having a similar issue. I also use Code is like this:
With
I cannote use I am using my own DataDocumentor now that uses a I can open a pull-request, if anybody is interested. |
From Johannes Dewender on 2013-01-22 17:41:15+00:00 I did open a pull-request: pull request #109 |
FWIW, I had a need for a similar feature too. Although, for now, I was able to remove the values by by using a custom css:
I know, not the most ideal thing, but gets my job done. |
Since 3.4.0, autodoc and autoattribute support In addition to this, I posted #8596 to suppress it via metadata in the docstring. Hence, I consider this issue has been resolved finally. Thanks. |
I keep running into this problem. This seems too hard.
I have a bunch of objects in Python from which I want to extract the docstring. I'm using ::autodata::
By default, I am seeing something like this:
What I would prefer is just
Even implementing the process-signature event, this seems not properly possible, since both return values are only appended to the basename.
Interestingly, when autodoc-process-signature does return a value in either field of the tuple (unfortunately, not an empty string), the string that is used for the base DOES change. So, with::
the output is:
as opposed to:
which seems like it might simply be an unintended effect.
I would love to see some way to fetch docstrings and insert them into the documentation without the constraints of autodoc.
The text was updated successfully, but these errors were encountered: