[Python-projects] pylint --output-format option
Mads Kiilerich
mads at kiilerich.com
Tue Feb 10 21:52:58 CET 2009
Saegebrecht Martin wrote, On 02/10/2009 12:51 PM:
> the options: --output-format and --files-output seems to conflict with
> each other.
>
> If I write:
>
> /pylint --output-format=html foo.py/ I get the output in html on
> standard output (and yes you can pipe it to a file if you whant to but
> thats not the issue here)
>
> But if I write:
>
> /pylint --output-format=html --files-output=y foo.py/ I get
> pylint_foo.html but this file is EMPTY?
>
> Why?
The more interesting question is if it is intended behaviour. I don't
think so.
To answer your question: That's because the output is set to use the
right output file, but for HTML the messages are buffered to ensure that
they are written in one well-formed chunk, and the pending messages
isn't flushed before the output is changed, so all messages ends up in
pylint_global.html.
The attached patch attempts to fix it.
/Mads
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: html-files-output.diff
URL: <http://lists.logilab.org/pipermail/python-projects/attachments/20090210/43707290/attachment.txt>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3435 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.logilab.org/pipermail/python-projects/attachments/20090210/43707290/attachment.bin>
More information about the Python-Projects
mailing list