Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exit code #50

Closed
wernight opened this issue Oct 14, 2014 · 6 comments
Closed

Exit code #50

wernight opened this issue Oct 14, 2014 · 6 comments

Comments

@wernight
Copy link

It's hard to make it part of CI because:

  • There is no Jenkins plugin that can read the outputs (if there is, please add it to the Wiki).
  • The tool doesn't exit code 1 or more when there are lint warnings/errors

I'd suggest first to support exit code.

@carlio
Copy link
Member

carlio commented Oct 14, 2014

Hi @wernight, the exit code change is supported on the development branch and will make it into the next release - see #46

As for plugins, there is a "pylint" output mode for prospector which would hopefully make it useable in place of tools which parse pylint output. See http://prospector.readthedocs.org/en/latest/usage.html#output-format . I have no idea if this works in practise though!

@wernight
Copy link
Author

Pylint output is text as far as I saw. Most parser use pylint XML output.

Thanks for the exit code, I'll make sure to track next release.

Le mar. 14 oct. 2014 22:57, carlio notifications@github.com a écrit :

Hi @wernight https://github.com/wernight, the exit code change is
supported on the development branch and will make it into the next release

As for plugins, there is a "pylint" output mode for prospector which would
hopefully make it useable in place of tools which parse pylint output. See
http://prospector.readthedocs.org/en/latest/usage.html#output-format . I
have no idea if this works in practise though!


Reply to this email directly or view it on GitHub
#50 (comment)
.

carlio added a commit that referenced this issue Oct 20, 2014
…the output format is still handled correctly by the Jenkins violations plugin
@carlio
Copy link
Member

carlio commented Oct 20, 2014

@wernight I've been testing, and you can use the output of prospector with the Jenkins violations plugin. I'll post some instructions on the landscape blog but it's quite simple:

prospector --output-format pylint > prospector.log

Then point the pylint section of the violations plugin at the prospector output.

It's not perfect - all errors are recognised as 'medium' severity - but it's good enough for now. I'll see if I can dust off my Java skills and add a pull request to the Violations plugin.

@carlio
Copy link
Member

carlio commented Oct 20, 2014

I'll close this issue, as the exit code is now implemented in release 0.7, and the XML output is covered by #32.

@carlio carlio closed this as completed Oct 20, 2014
@carlio
Copy link
Member

carlio commented Oct 21, 2014

Here is the blog post with information about how to get prospector running in Jenkins:
http://blog.landscape.io/using-prospector-in-jenkins-the-slightly-hacky-version.html

@wernight
Copy link
Author

Awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants