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 mixmastamyk
Recipients mixmastamyk
Date 2009-04-30.01:06:30
SpamBayes Score 7.2912485e-08
Marked as misclassified No
Message-id <1241053592.21.0.872598622661.issue5884@psf.upfronthosting.co.za>
In-reply-to
Content
When pydoc is run from the command line and unable to write a file for a
module because of a syntax error, it would be helpful to return a
non-zero status code as a result.

What it does currently:
    C:\>C:\python26\Lib\pydoc.py -w mymod
    problem in .\mymod.py - <type 'exceptions.SyntaxError'>: invalid
syntax (mymod.py, line 1)

    C:\>echo %ERRORLEVEL%
    0

What it should do if an error is found:
    C:\>type doesnt_exist.txt
    The system cannot find the file specified.

    C:\>echo %ERRORLEVEL%
    1


This would allow us to make our build scripts able to react to error
conditions, etc without having to use another script.  Thanks.
History
Date User Action Args
2009-04-30 01:06:32mixmastamyksetrecipients: + mixmastamyk
2009-04-30 01:06:32mixmastamyksetmessageid: <1241053592.21.0.872598622661.issue5884@psf.upfronthosting.co.za>
2009-04-30 01:06:31mixmastamyklinkissue5884 messages
2009-04-30 01:06:30mixmastamykcreate