John Snow <js...@redhat.com> writes: > On 4/25/21 9:27 AM, Markus Armbruster wrote: >> Another ignorant doc string markup question... how am I supposed to see >> that exprs and docs are attributes, and not global variables? >> > > The syntax is apparently supposed to be :py:attr:`MyClass.attr`. Though, > it doesn't seem to be working for me. I can write :py:attr:`bzbxglkdsgl` > and the build succeeds. I gotta hunch:
[Problems...] > > ____ ___ ___ ___ _ > | __ ) / _ \ / _ \ / _ \| | > | _ \| | | | | | | | | | | > | |_) | |_| | |_| | |_| |_| > |____/ \___/ \___/ \___/(_) > > > Sigh. Well, while I'm here doing the research and talking to myself, the > syntax :attr:`exprs` also works when you have the target defined. It > doesn't have to be as verbose. With my testing setup of using the > default role of "any", even just `exprs` works. > > I wonder if there's the possibility of having sphinx enhance :ivar: and > :cvar: to automatically create the same kind of reference target as > py:attribute:: does. > > Problems for later. > > For now ... > > ``.exprs`` and ``.docs``? Works for me.