This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients docs@python, eric.araujo, ezio.melotti, georg.brandl, sandro.tosi, taschini, terry.reedy
Date 2012-05-20.21:10:46
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1337548247.33.0.496140801969.issue12947@psf.upfronthosting.co.za>
In-reply-to
Content
The directives should normally be stripped, but not when they are intentionally given to teach their existence, syntax, and use, as in the doctest doc on directives.

I opened (and closed -- am trying to anyway) a duplicate, #14865. The problem of directive stripping started in 3.2.0 and subsequently 2.7.3 (after 2.7.2 in June 2011) and contiues in 3.3.0. Sandro Tosi noted

[1] https://bitbucket.org/birkenfeld/sphinx/issue/169/strip-doctest-csomments-in-rendered-output
[2] https://bitbucket.org/birkenfeld/sphinx/changeset/d91bf8e465ef
Issue and commit from June 2009.

My question is whether the added true-by-default ``trim_doctest_flags`` config value can just be added to doctest.rst? That would seem to be the point of having a settable config value, but I am ignorant of how sphinx works. I see that the patch does that, but also a lot more.

In any case, this is a nasty regression in the docs and should be fixed somehow before the next releases. It makes the examples actively confusing.
History
Date User Action Args
2012-05-20 21:10:47terry.reedysetrecipients: + terry.reedy, georg.brandl, ezio.melotti, eric.araujo, sandro.tosi, docs@python, taschini
2012-05-20 21:10:47terry.reedysetmessageid: <1337548247.33.0.496140801969.issue12947@psf.upfronthosting.co.za>
2012-05-20 21:10:46terry.reedylinkissue12947 messages
2012-05-20 21:10:46terry.reedycreate