Description / Features
This plugin enables the analysis of Python projects.
This plugin has following dependencies:
- Pylint is used for the rules compliance analysis.
- Install the Python plugin through the Update Center
- Restart Sonar
Python plugin uses the following properties during analysis. See here for the ways how to pass them to the plugin.
Path to the pylint executable to use in pylint analysis. Set to empty to use the default one.
Path to the pylint configuration file (relative to project root) to use in pylint analysis. Set to empty to use the default.
Comma separated list of paths relative to project root to add to PYTHONPATH when executing pylint.
You can analyze your projects using the usual means (see this page for all available). Just make sure to set a couple of properties. See below how to do it for maven and sonar-runner.
Analyzing with maven
Add your source directories to the build and the language-property to the properties section of your pom. Syntax:
Make sure the dynamic analysis is not switched off. Syntax:
- Make sure sonar-server is running
Start the analysis with
See here for general information about analyzing via maven.
Analyzing with sonar-runner
- Add a
sonar-project.properties-file to the root directory of your project
- Make sure your sonar-server is running
sonar-runnerin the directory containing the
See here for general information about analyzing via sonar-runner.
... is available here.
Version 1.0 (26 issues)
Version 0.1 (5 issues)
|SONARPLUGINS-1547||Make the pylint integration configurable||Closed||Fixed|
|SONARPLUGINS-1639||Support of code duplication detection||Closed||Fixed|
|SONARPLUGINS-1635||Rework the recognition of basic program entities||Closed||Fixed|
|SONARPLUGINS-1634||Improve the pylint integration||Closed||Fixed|
|SONARPLUGINS-1573||Add a colorizer for python code||Closed||Fixed|