Control: forwarded -1 https://github.com/sphinx-doc/sphinx/issues/2844

Hi Petter,

On Tue, Aug 09, 2016 at 01:08:23AM +0200, Petter Reinholdtsen wrote:
> Hi.  The documentation generated by sphinx expands default python
> arguments instead of reproducing the values listed in the source.

Thanks for the bug report. Indeed such behavior is not only breaking the
reproducible builds, but also a bit misleading.

However I think this may be non-trivial to fix, as Sphinx tries to import
the module, rather than parse it, and Python evaluates the arguments during
module import.

The same result (evaluated argument) can be seen if you call the built-in
help() against that function.

Speaking about your example, I would recommend against using such functions
at all: the default argument of that function is module *import* time,
not the actual time when it is executed; this is not what one may expect.

In any case, I have forwarded this bug to upstream developers, let's see
what they think about it.

--
Dmitry Shachnev

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Python-modules-team mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/python-modules-team

Reply via email to