Hi Peter,

>From v1.6, we started to enable smart_quotes option of docutils.
It seems your case might be a side effect of that.

As a quick look, docutils replaces nodes of Text subclasses to Text node.
Usually Text nodes are only used to represent texts (strings). So I feel a
bit strange to derive Text node.

Thanks,
Takeshi KOMIYA

2017-05-24 6:32 GMT+09:00 Peter Eastman <[email protected]>:

> I just upgraded from 1.5.1 to 1.6.1, and one of my extensions has stopped
> working.  I haven't been able to figure out why.  The source code for the
> extension is at https://github.com/pandegroup/openmm/blob/master/docs-
> source/sphinx/autonumber.py.
>
> The extension defines a new role, and a new class to represent it.  I
> verified that the role function is still getting called as expected.  It
> creates and returns an instance of the new class for each node:
>
> def autonumber_role(name, rawtext, text, lineno, inliner, options={},
> content=[]):
>    return ([autonumber(text)], [])
>
> But somehow those objects are getting thrown away.  When it gets to 
> doctree_resolved(),
> I find those nodes are represented by instances of docutils.nodes.Text
> instead of the objects I created in that function.  It worked correctly in
> 1.5.1.
>
> Thanks in advance for your help!
>
> --
> You received this message because you are subscribed to the Google Groups
> "sphinx-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/sphinx-users.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to