Issues

Issue #781 new

`autodoc` should fail when an auto* object is not of the right type

masklinn
created an issue

Spent some time today trying to find out why an autodoc directive just displayed {{{

!python

{module_name}

    alias of {module_name}

}}} with a link to itself.

Turns out it's because there had been some refactoring around, and I had not paid enough attention to the directives I was altering, resulting in trying to document a module via {{{autoclass}}}.

It would be nice if autodoc raised an error (I believe it has access to "live" python objects at this point) for this sort of type errors, fixing this mistake would have been much faster if Sphinx had just told me I was trying to document a module via autoclass (or the other way around).

Comments (2)

  1. Log in to comment