Commit c560652
committed
Fix regression in numpy#81
It seems numpy#81 introduced some kind of bug:
I have the following rst file documenting MyClass object from ottemplate module:
```
.. currentmodule:: ottemplate
.. autosummary::
:toctree: _generated/
:template: class.rst_t
MyClass
```
with class.rst_t:
```
{{ objname }}
{{ underline }}
.. currentmodule:: {{ module }}
.. autoclass:: {{ objname }}
{% block methods %}
.. automethod:: __init__
{% endblock %}
```
results in the following error:
```
following exception was raised:
Traceback (most recent call last):
File "/home/schueller/.local/lib/python3.5/site-packages/sphinx/ext/autodoc.py", line 551, in import_object
__import__(self.modname)
ImportError: No module named 'ottemplate.ottemplate.MyClass'; 'ottemplate.ottemplate' is not a package
```
What do you think @sirno ?1 parent 6df5c12 commit c560652
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
| |||
138 | 139 | | |
139 | 140 | | |
140 | 141 | | |
141 | | - | |
| 142 | + | |
142 | 143 | | |
143 | 144 | | |
144 | 145 | | |
| |||
0 commit comments