Menu

#1 System Exit: 28 from pylint

0.3.2
open-fixed
5
2009-05-02
2009-04-06
ennui77
No

I'm setting up NoseXUnit to run in hudson. I have the test reporting and code coverage working. However I cannot get the auditing with pylint to work. I'm using the following version of the dependent libraries:

coverage-2.85
kid-0.9.6
logilab-astng-0.19.0
logilab-common-0.39.0
nose-0.10.4
NoseXUnit-0.3.2
Pygments-1.0
pylint-0.18.0

when I try to run the audit I get the following error:

> nosetests --with-nosexunit --source-folder=trunk/src --enable-audit trunk/test

nose.nosexunit.audit: ERROR: Traceback (most recent call last):
File "build\bdist.win32\egg\nosexunit\audit\__init__.py", line 395, in server
File "c:\python24\lib\site-packages\pylint-0.18.0-py2.4.egg\pylint\lint.py", line 883, in __init__
sys.exit(self.linter.msg_status)
SystemExit: 28

Traceback (most recent call last):
File "C:\Python24\Scripts\nosetests-script.py", line 7, in ?
sys.exit(
File "c:\python24\lib\site-packages\nose-0.10.4-py2.4.egg\nose\core.py", line219, in __init__
argv=argv, testRunner=testRunner, testLoader=testLoader)
File "C:\Python24\lib\unittest.py", line 758, in __init__
self.parseArgs(argv)
File "c:\python24\lib\site-packages\nose-0.10.4-py2.4.egg\nose\core.py", line236, in parseArgs
self.config.configure(argv, doc=TestProgram.__doc__)
File "c:\python24\lib\site-packages\nose-0.10.4-py2.4.egg\nose\config.py", line 295, in configure
self.plugins.begin()
File "c:\python24\lib\site-packages\nose-0.10.4-py2.4.egg\nose\plugins\manager.py", line 81, in __call__
return self.call(*arg, **kw)
File "c:\python24\lib\site-packages\nose-0.10.4-py2.4.egg\nose\plugins\manager.py", line 145, in simple
result = meth(*arg, **kw)
File "build\bdist.win32\egg\nosexunit\plugin.py", line 275, in begin
File "build\bdist.win32\egg\nosexunit\plugin.py", line 235, in initialize
File "build\bdist.win32\egg\nosexunit\audit\__init__.py", line 271, in audit
File "build\bdist.win32\egg\nosexunit\audit\__init__.py", line 367, in client
nosexunit.excepts.AuditError: failed to audit source

I was under the impression that the system exit 28 from lint.py is a valid error condition. This is from the pylint:

Output status code:
Pylint should leave with following status code:
* 0 if everything went fine
* 1 if some fatal message issued
* 2 if some error message issued
* 4 if some warning message issued
* 8 if some refactor message issued
* 16 if some convention message issued
* 32 on usage error
status 1 to 16 will be bit-ORed so you can know which different
categories has been issued by analysing pylint output status code

Am I doing something wrong here? What can I do track this down?

Discussion

  • Olivier Mansion

    Olivier Mansion - 2009-05-02

    In its version 0.3.2, NoseXUnit checks that the return code of PyLint subprocess is in following dictionary's values:

    pylint.utils.MSG_TYPES_STATUS

    Unfortunately, the exit code of PyLint is a OR operation on all messages due to the following line:

    self.msg_status |= MSG_TYPES_STATUS[msg_id[0]] # (line 250 of pylint.utils)

    So there is a bug in the check function.

    This is corrected in trunk version.

     
  • Olivier Mansion

    Olivier Mansion - 2009-05-02
    • assigned_to: nobody --> omansion
    • status: open --> open-fixed
     
  • Olivier Mansion

    Olivier Mansion - 2009-05-02
    • labels: --> Audit (PyLint)
    • milestone: --> 0.3.2
     
  • ennui77

    ennui77 - 2009-05-04

    Thanks, I will try the trunk version/

     

Log in to post a comment.

MongoDB Logo MongoDB