Sonarqube CL scanner not catching Python smells

I have a local install of Sonarqube (using Docker and using WSL2 command line - Linux subsystem on Windows). I am running the local scanner to analyze Python scripts that have been purposely generated with smells. The scanner runs without errors. The rules are downloaded without issue etc. The Sonarqube server runs fine (though it notes there is no test coverage of the Python code - I haven’t set up an external test for that). There is no SCM - just .py files in a local folder. No smells are reported in Python, however. Yet when I try the same process with Java files (again, purposely generated code with smells) the smells are reported.

I’m wondering if there is some additional configuration with Python?

Thank you for any thoughts.

sonar-project.properties:

must be unique in a given SonarQube instance

sonar.projectKey=TestSonarqube
sonar.projectName=TestSonarqube
sonar.projectBaseDir=/home/ncombs/Dev/Sonarqube_a_experiment
#----- Default SonarQube server
sonar.host.url=http://localhost:9000
sonar.language=py,java
sonar.sources=src/main/
sonar.tests=src/tests/
sonar.python.version=3.7
sonar.sourceEncoding=UTF-8
sonar.verbose=true

CL:
sonar-scanner -X -Dsonar.token=

Scanner transcript:


4:51:43.949 INFO: Scanner configuration file: /home/ncombs/Dev/Sonarqube_a_experiment/sonar-scanner-5.0.1.3006-linux/conf/sonar-scanner.properties
04:51:43.967 INFO: Project root configuration file: /home/ncombs/Dev/Sonarqube_a_experiment/sonar-project.properties
04:51:43.994 INFO: SonarScanner 5.0.1.3006
04:51:43.994 INFO: Java 17.0.7 Eclipse Adoptium (64-bit)
04:51:43.994 INFO: Linux 5.15.133.1-microsoft-standard-WSL2 amd64
04:51:44.125 DEBUG: keyStore is : 
04:51:44.125 DEBUG: keyStore type is : pkcs12
04:51:44.125 DEBUG: keyStore provider is : 
04:51:44.125 DEBUG: init keystore
04:51:44.126 DEBUG: init keymanager of type SunX509
04:51:44.214 DEBUG: Create: /home/ncombs/.sonar/cache
04:51:44.215 INFO: User cache: /home/ncombs/.sonar/cache
04:51:44.215 DEBUG: Create: /home/ncombs/.sonar/cache/_tmp
04:51:44.217 DEBUG: Extract sonar-scanner-api-batch in temp...
04:51:44.219 DEBUG: Get bootstrap index...
04:51:44.220 DEBUG: Download: http://localhost:9000/batch/index
04:51:44.267 DEBUG: Get bootstrap completed
04:51:44.269 DEBUG: Create isolated classloader...
04:51:44.280 DEBUG: Start temp cleaning...
04:51:44.284 DEBUG: Temp cleaning done
04:51:44.285 DEBUG: Execution getVersion
04:51:44.297 INFO: Analyzing on SonarQube server 10.4.0.87286
04:51:44.298 INFO: Default locale: "en", source code encoding: "UTF-8"
04:51:44.298 DEBUG: Work directory: /home/ncombs/Dev/Sonarqube_a_experiment/.scannerwork
04:51:44.299 DEBUG: Execution execute
04:51:44.581 DEBUG: Community 10.4.0.87286
04:51:44.817 INFO: Load global settings
04:51:44.861 DEBUG: GET 200 http://localhost:9000/api/settings/values.protobuf | time=43ms
04:51:44.899 INFO: Load global settings (done) | time=82ms
04:51:44.904 INFO: Server id: 147B411E-AY2lIyJ6rBUsyTpukOuA
04:51:44.924 INFO: User cache: /home/ncombs/.sonar/cache
04:51:44.932 WARN: sonar.plugins.downloadOnlyRequired is false, so ALL available plugins will be downloaded
04:51:44.933 INFO: Loading all plugins
04:51:44.933 INFO: Load plugins index
04:51:44.946 DEBUG: GET 200 http://localhost:9000/api/plugins/installed | time=12ms
04:51:44.984 INFO: Load plugins index (done) | time=51ms
04:51:44.984 INFO: Load/download plugins
04:51:45.095 INFO: Load/download plugins (done) | time=110ms
04:51:45.162 DEBUG: Plugins loaded:
04:51:45.162 DEBUG:   * Python Code Quality and Security 4.14.0.14263 (python)
04:51:45.162 DEBUG:   * Clean as You Code 2.3.0.1782 (cayc)
04:51:45.162 DEBUG:   * Go Code Quality and Security 1.15.0.4655 (go)
04:51:45.163 DEBUG:   * JaCoCo 1.3.0.1538 (jacoco)
04:51:45.163 DEBUG:   * Kotlin Code Quality and Security 2.20.0.4382 (kotlin)
04:51:45.163 DEBUG:   * IaC Code Quality and Security 1.26.0.8471 (iac)
04:51:45.163 DEBUG:   * JavaScript/TypeScript/CSS Code Quality and Security 10.11.1.25225 (javascript)
04:51:45.163 DEBUG:   * Ruby Code Quality and Security 1.15.0.4655 (ruby)
04:51:45.163 DEBUG:   * Scala Code Quality and Security 1.15.0.4655 (sonarscala)
04:51:45.164 DEBUG:   * C# Code Quality and Security 9.19.0.84025 (csharp)
04:51:45.164 DEBUG:   * Java Code Quality and Security 7.30.0.34429 (java)
04:51:45.164 DEBUG:   * HTML Code Quality and Security 3.13.0.4821 (web)
04:51:45.164 DEBUG:   * Flex Code Quality and Security 2.12.0.4568 (flex)
04:51:45.164 DEBUG:   * XML Code Quality and Security 2.10.0.4108 (xml)
04:51:45.164 DEBUG:   * PHP Code Quality and Security 3.33.0.11274 (php)
04:51:45.165 DEBUG:   * Text Code Quality and Security 2.8.0.1635 (text)
04:51:45.165 DEBUG:   * VB.NET Code Quality and Security 9.19.0.84025 (vbnet)
04:51:45.893 INFO: Process project properties
04:51:45.907 INFO: Process project properties (done) | time=15ms
04:51:45.911 INFO: Execute project builders
04:51:45.912 DEBUG: Execute project builder: org.sonar.plugins.csharp.CSharpGlobalProtobufFileProcessor
04:51:45.913 DEBUG: Execute project builder: org.sonar.plugins.vbnet.VbNetGlobalProtobufFileProcessor
04:51:45.915 INFO: Execute project builders (done) | time=4ms
04:51:45.931 INFO: Project key: TestSonarqube
04:51:45.932 INFO: Base dir: /home/ncombs/Dev/Sonarqube_a_experiment
04:51:45.932 INFO: Working dir: /home/ncombs/Dev/Sonarqube_a_experiment/.scannerwork
04:51:45.932 DEBUG: Project global encoding: UTF-8, default locale: en
04:51:45.956 INFO: Load project settings for component key: 'TestSonarqube'
04:51:45.985 DEBUG: GET 200 http://localhost:9000/api/settings/values.protobuf?component=TestSonarqube | time=29ms
04:51:45.988 INFO: Load project settings for component key: 'TestSonarqube' (done) | time=32ms
04:51:46.198 DEBUG: Creating module hierarchy
04:51:46.199 DEBUG:   Init module 'TestSonarqube'
04:51:46.201 DEBUG:     Base dir: /home/ncombs/Dev/Sonarqube_a_experiment
04:51:46.201 DEBUG:     Working dir: /home/ncombs/Dev/Sonarqube_a_experiment/.scannerwork
04:51:46.202 DEBUG:     Module global encoding: UTF-8, default locale: en
04:51:46.226 INFO: Load quality profiles
04:51:46.299 DEBUG: GET 200 http://localhost:9000/api/qualityprofiles/search.protobuf?project=TestSonarqube | time=71ms
04:51:46.333 INFO: Load quality profiles (done) | time=107ms
04:51:46.377 DEBUG: SCM Step is disabled by configuration
04:51:46.382 INFO: Load active rules
04:51:46.481 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=c03f43dc-60fb-4845-a86c-02ad00738d96&ps=500&p=1 | time=98ms
04:51:46.722 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=9a379281-5a79-4483-bf4a-3b1e8ac4c6c3&ps=500&p=1 | time=74ms
04:51:46.810 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=f1edc338-88ef-408f-9317-c209422fc066&ps=500&p=1 | time=78ms
04:51:46.827 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=0ad4bb91-60b4-4ee4-aa03-540799ae9a41&ps=500&p=1 | time=10ms
04:51:47.748 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=6cdff11d-7e7a-4e62-b932-7e153f57ab2a&ps=500&p=1 | time=920ms
04:51:48.758 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=3f847a64-7653-486c-aa38-c32dd66ae75d&ps=500&p=1 | time=971ms
04:51:48.896 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=4d5d51e4-42c0-4567-af7d-540edccbdc18&ps=500&p=1 | time=118ms
04:51:50.056 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=45ee41db-f067-40c3-b245-2d0f29782d8b&ps=500&p=1 | time=1157ms
04:51:50.189 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=1742b12c-37fa-4a13-8fae-db3c13672f63&ps=500&p=1 | time=88ms
04:51:50.286 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=57636e28-a43f-4746-8259-99a70be64a25&ps=500&p=1 | time=95ms
04:51:50.363 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=4f1b404a-b8b9-4634-b71e-d9adc8147360&ps=500&p=1 | time=74ms
04:51:50.372 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=b30a08be-2f1e-465f-a617-61a59f4c6b62&ps=500&p=1 | time=8ms
04:51:50.391 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=daba5d31-2a73-49d7-8e66-eb1141dfd2cb&ps=500&p=1 | time=18ms
04:51:50.805 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=95bbd332-f2a4-406b-8e0e-bd263550259b&ps=500&p=1 | time=414ms
04:51:50.898 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=ea058fda-0362-457b-8a7e-c9377b192fa0&ps=500&p=1 | time=89ms
04:51:50.907 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=a10868e6-c1df-44bb-b680-5574ae0410e7&ps=500&p=1 | time=8ms
04:51:50.967 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=1d50db7d-53f7-40e4-9598-79d3d3cbdf94&ps=500&p=1 | time=60ms
04:51:51.276 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=76a1fdb9-94a2-4f6e-91c3-68983a5337a5&ps=500&p=1 | time=308ms
04:51:51.492 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=94bfe097-47c5-4fd1-870f-8342bb9541ae&ps=500&p=1 | time=211ms
04:51:51.556 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=adb93a55-23a1-46a0-b75d-9e456badaa89&ps=500&p=1 | time=61ms
04:51:52.216 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=99811493-ee2b-41e5-ad03-b36c7b547c6a&ps=500&p=1 | time=659ms
04:51:52.687 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=d50dec84-0847-4c66-abdd-5b13a65151d3&ps=500&p=1 | time=463ms
04:51:52.845 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=39c49700-1580-4f76-830e-9eb1923a9a78&ps=500&p=1 | time=152ms
04:51:52.917 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=66dee01e-47ae-4ec0-81bc-17d495026121&ps=500&p=1 | time=70ms
04:51:53.847 DEBUG: GET 200 http://localhost:9000/api/rules/list.protobuf?qprofile=67f15717-8d54-4b2a-8382-44522cabba65&ps=500&p=1 | time=929ms
04:51:53.871 INFO: Load active rules (done) | time=7489ms
04:51:53.877 INFO: Load analysis cache
04:51:53.893 DEBUG: GET 200 http://localhost:9000/api/analysis_cache/get?project=TestSonarqube | time=15ms
04:51:53.902 INFO: Load analysis cache (7.1 kB) | time=25ms
04:51:53.927 DEBUG: GET 200 http://localhost:9000/api/languages/list | time=6ms
04:51:53.973 DEBUG: Declared patterns of language Kubernetes were converted to sonar.lang.patterns.kubernetes : 
04:51:53.975 DEBUG: Declared patterns of language CSS were converted to sonar.lang.patterns.css : **/*.css,**/*.less,**/*.scss,**/*.sass
04:51:53.975 DEBUG: Declared patterns of language Scala were converted to sonar.lang.patterns.scala : **/*.scala
04:51:53.976 DEBUG: Declared patterns of language JSP were converted to sonar.lang.patterns.jsp : **/*.jsp,**/*.jspf,**/*.jspx
04:51:53.976 DEBUG: Declared patterns of language JavaScript were converted to sonar.lang.patterns.js : **/*.js,**/*.jsx,**/*.cjs,**/*.mjs,**/*.vue
04:51:53.976 DEBUG: Declared patterns of language Python were converted to sonar.lang.patterns.py : **/*.py
04:51:53.977 DEBUG: Declared patterns of language Docker were converted to sonar.lang.patterns.docker : **/Dockerfile,**/*.dockerfile
04:51:53.977 DEBUG: Declared patterns of language Java were converted to sonar.lang.patterns.java : **/*.java,**/*.jav
04:51:53.978 DEBUG: Declared patterns of language HTML were converted to sonar.lang.patterns.web : **/*.html,**/*.xhtml,**/*.cshtml,**/*.vbhtml,**/*.aspx,**/*.ascx,**/*.rhtml,**/*.erb,**/*.shtm,**/*.shtml,**/*.cmp,**/*.twig
04:51:53.979 DEBUG: Declared patterns of language Flex were converted to sonar.lang.patterns.flex : **/*.as
04:51:53.980 DEBUG: Declared patterns of language XML were converted to sonar.lang.patterns.xml : **/*.xml,**/*.xsd,**/*.xsl,**/*.config
04:51:53.981 DEBUG: Declared patterns of language JSON were converted to sonar.lang.patterns.json : **/*.json
04:51:53.981 DEBUG: Declared patterns of language Text were converted to sonar.lang.patterns.text : 
04:51:53.981 DEBUG: Declared patterns of language VB.NET were converted to sonar.lang.patterns.vbnet : **/*.vb
04:51:53.982 DEBUG: Declared patterns of language CloudFormation were converted to sonar.lang.patterns.cloudformation : 
04:51:53.983 DEBUG: Declared patterns of language YAML were converted to sonar.lang.patterns.yaml : **/*.yaml,**/*.yml
04:51:53.983 DEBUG: Declared patterns of language Go were converted to sonar.lang.patterns.go : **/*.go
04:51:53.983 DEBUG: Declared patterns of language Kotlin were converted to sonar.lang.patterns.kotlin : **/*.kt,**/*.kts
04:51:53.984 DEBUG: Declared patterns of language Secrets were converted to sonar.lang.patterns.secrets : 
04:51:53.984 DEBUG: Declared patterns of language Ruby were converted to sonar.lang.patterns.ruby : **/*.rb
04:51:53.985 DEBUG: Declared patterns of language C# were converted to sonar.lang.patterns.cs : **/*.cs,**/*.razor
04:51:53.985 DEBUG: Declared patterns of language PHP were converted to sonar.lang.patterns.php : **/*.php,**/*.php3,**/*.php4,**/*.php5,**/*.phtml,**/*.inc
04:51:53.986 DEBUG: Declared patterns of language Terraform were converted to sonar.lang.patterns.terraform : **/*.tf
04:51:53.987 DEBUG: Declared patterns of language AzureResourceManager were converted to sonar.lang.patterns.azureresourcemanager : **/*.bicep
04:51:53.988 DEBUG: Declared patterns of language TypeScript were converted to sonar.lang.patterns.ts : **/*.ts,**/*.tsx,**/*.cts,**/*.mts
04:51:54.001 INFO: Preprocessing files...
04:51:54.028 INFO: 2 languages detected in 6 preprocessed files
04:51:54.113 INFO: Load project repositories
04:51:54.136 DEBUG: GET 200 http://localhost:9000/batch/project.protobuf?key=TestSonarqube | time=23ms
04:51:54.148 INFO: Load project repositories (done) | time=35ms
04:51:54.184 DEBUG: Will ignore generated code
04:51:54.190 DEBUG: Will ignore generated code
04:51:54.240 DEBUG: Available languages:
04:51:54.240 DEBUG:   * Python => "py"
04:51:54.241 DEBUG:   * Go => "go"
04:51:54.241 DEBUG:   * Kotlin => "kotlin"
04:51:54.241 DEBUG:   * Terraform => "terraform"
04:51:54.241 DEBUG:   * CloudFormation => "cloudformation"
04:51:54.241 DEBUG:   * Kubernetes => "kubernetes"
04:51:54.241 DEBUG:   * Docker => "docker"
04:51:54.241 DEBUG:   * AzureResourceManager => "azureresourcemanager"
04:51:54.242 DEBUG:   * YAML => "yaml"
04:51:54.242 DEBUG:   * JSON => "json"
04:51:54.242 DEBUG:   * JavaScript => "js"
04:51:54.242 DEBUG:   * TypeScript => "ts"
04:51:54.242 DEBUG:   * CSS => "css"
04:51:54.242 DEBUG:   * Ruby => "ruby"
04:51:54.242 DEBUG:   * Scala => "scala"
04:51:54.243 DEBUG:   * C# => "cs"
04:51:54.243 DEBUG:   * Java => "java"
04:51:54.243 DEBUG:   * HTML => "web"
04:51:54.243 DEBUG:   * JSP => "jsp"
04:51:54.243 DEBUG:   * Flex => "flex"
04:51:54.243 DEBUG:   * XML => "xml"
04:51:54.243 DEBUG:   * PHP => "php"
04:51:54.244 DEBUG:   * Text => "text"
04:51:54.244 DEBUG:   * Secrets => "secrets"
04:51:54.244 DEBUG:   * VB.NET => "vbnet"
04:51:54.246 INFO: Indexing files...
04:51:54.248 INFO: Project configuration:
04:51:54.265 DEBUG: 'src/main/cpp/ticTacToe.cpp' indexed with no language
04:51:54.273 DEBUG: 'src/main/java/ticTacToe.java' indexed with language 'java'
04:51:54.274 DEBUG: 'src/main/python/main.py' indexed with language 'py'
04:51:54.275 DEBUG: 'src/main/python/smelly_samples.py' indexed with language 'py'
04:51:54.275 DEBUG: 'src/main/python/TicTacToe.py' indexed with language 'py'
04:51:54.276 DEBUG: 'src/main/python/main_chatgpt_altered.py' indexed with language 'py'
04:51:54.280 INFO: 6 files indexed
04:51:54.284 INFO: Quality profile for java: Sonar way
04:51:54.284 INFO: Quality profile for py: Sonar way
04:51:54.285 INFO: ------------- Run sensors on module TestSonarqube
04:51:54.431 INFO: Load metrics repository
04:51:54.451 DEBUG: GET 200 http://localhost:9000/api/metrics/search?ps=500&p=1 | time=17ms
04:51:54.473 INFO: Load metrics repository (done) | time=42ms
04:51:55.376 DEBUG: Added 304 checks for language='ts', repository='typescript'
04:51:55.382 DEBUG: Added 303 checks for language='js', repository='javascript'
04:51:56.236 DEBUG: 'Import external issues report' skipped because one of the required properties is missing
04:51:56.238 DEBUG: 'Import of Pylint issues' skipped because one of the required properties is missing
04:51:56.238 DEBUG: 'Import of Bandit issues' skipped because one of the required properties is missing
04:51:56.238 DEBUG: 'Import of Flake8 issues' skipped because one of the required properties is missing
04:51:56.238 DEBUG: 'Import of Mypy issues' skipped because one of the required properties is missing
04:51:56.239 DEBUG: 'Import of Ruff issues' skipped because one of the required properties is missing
04:51:56.239 DEBUG: 'Code Quality and Security for Go' skipped because there is no related file in current project
04:51:56.240 DEBUG: 'Go Unit Test Report' skipped because there is no related file in current project
04:51:56.241 DEBUG: 'Go Cover sensor for Go coverage' skipped because there is no related file in current project
04:51:56.242 DEBUG: 'Import of go vet issues' skipped because there is no related file in current project
04:51:56.243 DEBUG: 'Import of Golint issues' skipped because there is no related file in current project
04:51:56.243 DEBUG: 'Import of GoMetaLinter issues' skipped because there is no related file in current project
04:51:56.243 DEBUG: 'Import of GolangCI-Lint issues' skipped because there is no related file in current project
04:51:56.244 DEBUG: 'Kotlin Sensor' skipped because there is no related file in current project
04:51:56.244 DEBUG: 'Gradle Sensor' skipped because there is no related file in current project
04:51:56.244 DEBUG: 'KotlinSurefireSensor' skipped because there is no related file in current project
04:51:56.245 DEBUG: 'Import of detekt issues' skipped because there is no related file in current project
04:51:56.246 DEBUG: 'Import of Android Lint issues' skipped because one of the required properties is missing
04:51:56.247 DEBUG: 'Import of ktlint issues' skipped because there is no related file in current project
04:51:56.252 DEBUG: 'IaC Terraform Sensor' skipped because there is no related file in current project
04:51:56.253 DEBUG: 'IaC CloudFormation Sensor' skipped because there is no related file in current project
04:51:56.254 DEBUG: 'IaC Kubernetes Sensor' skipped because there is no related file in current project
04:51:56.255 DEBUG: 'IaC AzureResourceManager Sensor' skipped because there is no related file in current project
04:51:56.255 DEBUG: 'JavaScript/TypeScript analysis' skipped because there is no related file in current project
04:51:56.255 DEBUG: 'JavaScript inside YAML analysis' skipped because there is no related file in current project
04:51:56.256 DEBUG: 'JavaScript inside HTML analysis' skipped because there is no related file in current project
04:51:56.257 DEBUG: 'JavaScript/TypeScript Coverage' skipped because there is no related file in current project
04:51:56.259 DEBUG: 'Import of ESLint issues' skipped because one of the required properties is missing
04:51:56.259 DEBUG: 'Import of TSLint issues' skipped because one of the required properties is missing
04:51:56.260 DEBUG: 'CSS Metrics' skipped because there is no related file in current project
04:51:56.260 DEBUG: 'Import of stylelint issues' skipped because one of the required properties is missing
04:51:56.262 DEBUG: 'Ruby Sensor' skipped because there is no related file in current project
04:51:56.264 DEBUG: 'Import of RuboCop issues' skipped because there is no related file in current project
04:51:56.266 DEBUG: 'SimpleCov Sensor for Ruby coverage' skipped because there is no related file in current project
04:51:56.267 DEBUG: 'Scala Sensor' skipped because there is no related file in current project
04:51:56.268 DEBUG: 'Scoverage sensor for Scala coverage' skipped because there is no related file in current project
04:51:56.269 DEBUG: 'Import of Scalastyle issues' skipped because there is no related file in current project
04:51:56.270 DEBUG: 'Import of Scapegoat issues' skipped because there is no related file in current project
04:51:56.271 DEBUG: 'Import of Checkstyle issues' skipped because one of the required properties is missing
04:51:56.272 DEBUG: 'Import of PMD issues' skipped because one of the required properties is missing
04:51:56.273 DEBUG: 'Import of SpotBugs issues' skipped because one of the required properties is missing
04:51:56.274 DEBUG: 'Removed properties sensor' skipped because one of the required properties is missing
04:51:56.275 DEBUG: 'Flex' skipped because there is no related file in current project
04:51:56.276 DEBUG: 'Flex Cobertura' skipped because there is no related file in current project
04:51:56.277 DEBUG: 'XML Sensor' skipped because there is no related file in current project
04:51:56.277 DEBUG: 'PHP sensor' skipped because there is no related file in current project
04:51:56.278 DEBUG: 'Analyzer for "php.ini" files' skipped because there is no related file in current project
04:51:56.278 DEBUG: 'PHPUnit report sensor' skipped because there is no related file in current project
04:51:56.280 DEBUG: 'Import of PHPStan issues' skipped because there is no related file in current project
04:51:56.281 DEBUG: 'Import of Psalm issues' skipped because there is no related file in current project
04:51:56.287 DEBUG: 'Generic Test Executions Report' skipped because one of the required properties is missing
04:51:56.289 DEBUG: Sensors : JavaSensor -> Python Sensor -> Cobertura Sensor for Python coverage -> PythonXUnitSensor -> JaCoCo XML Report Importer -> CSS Rules -> C# Project Type Information -> C# Analysis Log -> C# Properties -> SurefireSensor -> HTML -> TextAndSecretsSensor -> VB.NET Project Type Information -> VB.NET Analysis Log -> VB.NET Properties -> IaC Docker Sensor
04:51:56.291 INFO: Sensor JavaSensor [java]
04:51:56.310 DEBUG: Property 'sonar.java.jdkHome' resolved with:
[]
04:51:56.311 DEBUG: Property 'sonar.java.libraries' resolved with:
[]
04:51:56.312 DEBUG: Property 'sonar.java.jdkHome' resolved with:
[]
04:51:56.312 DEBUG: Property 'sonar.java.test.libraries' resolved with:
[]
04:51:56.325 INFO: Server-side caching is enabled. The Java analyzer will not try to leverage data from a previous analysis.
04:51:56.329 INFO: Using ECJ batch to parse 1 Main java source files with batch size 207 KB.
04:51:56.353 DEBUG: 'src/main/java/ticTacToe.java' generated metadata with charset 'UTF-8'
04:51:56.473 INFO: Starting batch processing.
04:51:57.024 INFO: The Java analyzer cannot skip unchanged files in this context. A full analysis is performed for all files.
04:51:57.323 DEBUG: [SE] Loaded 235 hardcoded method behaviors.
04:51:58.123 DEBUG: Analysis time of src/main/java/ticTacToe.java (1173ms)
04:51:58.135 INFO: 100% analyzed
04:51:58.135 INFO: Batch processing: Done.
04:51:58.137 INFO: Did not optimize analysis for any files, performed a full analysis for all 1 files.
04:51:58.142 WARN: Dependencies/libraries were not provided for analysis of SOURCE files. The 'sonar.java.libraries' property is empty. Verify your configuration, as you might end up with less precise results.
04:51:58.149 WARN: Use of preview features have been detected during analysis. Enable DEBUG mode to see them.
04:51:58.150 DEBUG: Use of preview features:
- The public type TicTacToeGame must be defined in its own file
  * src/main/java/ticTacToe.java
04:51:58.150 INFO: No "Test" source files to scan.
04:51:58.151 INFO: No "Generated" source files to scan.
04:51:58.151 INFO: Sensor JavaSensor [java] (done) | time=1861ms
04:51:58.151 INFO: Sensor Python Sensor [python]
04:51:58.188 DEBUG: Input files for indexing: [src/main/python/TicTacToe.py, src/main/python/main.py, src/main/python/main_chatgpt_altered.py, src/main/python/smelly_samples.py]
04:51:58.190 INFO: Starting global symbols computation
04:51:58.199 DEBUG: 'src/main/python/TicTacToe.py' generated metadata with charset 'UTF-8'
04:51:58.200 INFO: 4 source files to be analyzed
04:51:58.621 DEBUG: 'src/main/python/main.py' generated metadata with charset 'UTF-8'
04:51:58.782 DEBUG: 'src/main/python/main_chatgpt_altered.py' generated metadata with charset 'UTF-8'
04:51:58.831 DEBUG: 'src/main/python/smelly_samples.py' generated metadata with charset 'UTF-8'
04:51:58.851 INFO: 4/4 source files have been analyzed
04:51:58.894 INFO: Starting rules execution
04:51:58.896 INFO: 4 source files to be analyzed
04:51:59.532 DEBUG: Not enough content in 'src/main/python/smelly_samples.py' to have CPD blocks, it will not be part of the duplication detection
04:51:59.552 INFO: 4/4 source files have been analyzed
04:51:59.553 INFO: The Python analyzer was able to leverage cached data from previous analyses for 0 out of 4 files. These files were not parsed.
04:51:59.553 INFO: Sensor Python Sensor [python] (done) | time=1402ms
04:51:59.554 INFO: Sensor Cobertura Sensor for Python coverage [python]
04:51:59.554 DEBUG: Using pattern 'coverage-reports/*coverage-*.xml' to find reports
04:51:59.581 DEBUG: No report was found for sonar.python.coverage.reportPaths using default pattern coverage-reports/*coverage-*.xml
04:51:59.581 INFO: Sensor Cobertura Sensor for Python coverage [python] (done) | time=27ms
04:51:59.582 INFO: Sensor PythonXUnitSensor [python]
04:51:59.582 DEBUG: Using pattern 'xunit-reports/xunit-result-*.xml' to find reports
04:51:59.594 DEBUG: No report was found for sonar.python.xunit.reportPath using default pattern xunit-reports/xunit-result-*.xml
04:51:59.594 INFO: Sensor PythonXUnitSensor [python] (done) | time=12ms
04:51:59.595 INFO: Sensor JaCoCo XML Report Importer [jacoco]
04:51:59.598 INFO: 'sonar.coverage.jacoco.xmlReportPaths' is not defined. Using default locations: target/site/jacoco/jacoco.xml,target/site/jacoco-it/jacoco.xml,build/reports/jacoco/test/jacocoTestReport.xml
04:51:59.599 INFO: No report imported, no coverage information will be imported by JaCoCo XML Report Importer
04:51:59.599 INFO: Sensor JaCoCo XML Report Importer [jacoco] (done) | time=4ms
04:51:59.600 INFO: Sensor CSS Rules [javascript]
04:51:59.600 INFO: No CSS, PHP, HTML or VueJS files are found in the project. CSS analysis is skipped.
04:51:59.601 INFO: Sensor CSS Rules [javascript] (done) | time=2ms
04:51:59.601 INFO: Sensor C# Project Type Information [csharp]
04:51:59.602 INFO: Sensor C# Project Type Information [csharp] (done) | time=1ms
04:51:59.602 INFO: Sensor C# Analysis Log [csharp]
04:51:59.623 INFO: Sensor C# Analysis Log [csharp] (done) | time=21ms
04:51:59.623 INFO: Sensor C# Properties [csharp]
04:51:59.624 DEBUG: Project 'TestSonarqube': No Roslyn issues reports have been found.
04:51:59.624 INFO: Sensor C# Properties [csharp] (done) | time=1ms
04:51:59.625 INFO: Sensor SurefireSensor [java]
04:51:59.626 INFO: parsing [/home/ncombs/Dev/Sonarqube_a_experiment/target/surefire-reports]
04:51:59.628 INFO: Sensor SurefireSensor [java] (done) | time=3ms
04:51:59.628 INFO: Sensor HTML [web]
04:51:59.633 INFO: Sensor HTML [web] (done) | time=5ms
04:51:59.633 INFO: Sensor TextAndSecretsSensor [text]
04:52:00.073 INFO: 5 source files to be analyzed
04:52:00.168 INFO: 5/5 source files have been analyzed
04:52:00.168 INFO: Sensor TextAndSecretsSensor [text] (done) | time=535ms
04:52:00.169 INFO: Sensor VB.NET Project Type Information [vbnet]
04:52:00.170 INFO: Sensor VB.NET Project Type Information [vbnet] (done) | time=1ms
04:52:00.170 INFO: Sensor VB.NET Analysis Log [vbnet]
04:52:00.191 INFO: Sensor VB.NET Analysis Log [vbnet] (done) | time=21ms
04:52:00.192 INFO: Sensor VB.NET Properties [vbnet]
04:52:00.192 DEBUG: Project 'TestSonarqube': No Roslyn issues reports have been found.
04:52:00.192 INFO: Sensor VB.NET Properties [vbnet] (done) | time=0ms
04:52:00.193 INFO: Sensor IaC Docker Sensor [iac]
04:52:00.197 INFO: 0 source files to be analyzed
04:52:00.281 INFO: 0/0 source files have been analyzed
04:52:00.281 INFO: Sensor IaC Docker Sensor [iac] (done) | time=89ms
04:52:00.285 INFO: ------------- Run sensors on project
04:52:00.381 DEBUG: 'Generic Coverage Report' skipped because one of the required properties is missing
04:52:00.381 DEBUG: 'Import external issues report from SARIF file.' skipped because one of the required properties is missing
04:52:00.382 DEBUG: 'C#' skipped because there is no related file in current project
04:52:00.382 DEBUG: 'C# File Caching Sensor' skipped because there is no related file in current project
04:52:00.383 DEBUG: 'C# Tests Coverage Report Import' skipped because there is no related file in current project
04:52:00.384 DEBUG: '[Deprecated] C# Integration Tests Coverage Report Import' skipped because there is no related file in current project
04:52:00.384 DEBUG: 'C# Unit Test Results Import' skipped because there is no related file in current project
04:52:00.384 DEBUG: 'VB.NET' skipped because there is no related file in current project
04:52:00.385 DEBUG: 'VB.NET File Caching Sensor' skipped because there is no related file in current project
04:52:00.385 DEBUG: 'VB.NET Tests Coverage Report Import' skipped because there is no related file in current project
04:52:00.385 DEBUG: '[Deprecated] VB.NET Integration Tests Coverage Report Import' skipped because there is no related file in current project
04:52:00.386 DEBUG: 'VB.NET Unit Test Results Import' skipped because there is no related file in current project
04:52:00.387 DEBUG: Sensors : Analysis Warnings import -> Zero Coverage Sensor -> Java CPD Block Indexer
04:52:00.387 INFO: Sensor Analysis Warnings import [csharp]
04:52:00.389 INFO: Sensor Analysis Warnings import [csharp] (done) | time=2ms
04:52:00.390 INFO: Sensor Zero Coverage Sensor
04:52:00.404 INFO: Sensor Zero Coverage Sensor (done) | time=15ms
04:52:00.404 INFO: Sensor Java CPD Block Indexer
04:52:00.412 DEBUG: Populating index from src/main/java/ticTacToe.java
04:52:00.431 INFO: Sensor Java CPD Block Indexer (done) | time=27ms
04:52:00.432 INFO: SCM Publisher is disabled
04:52:00.436 INFO: CPD Executor 1 file had no CPD blocks
04:52:00.437 INFO: CPD Executor Calculating CPD for 4 files
04:52:00.438 DEBUG: Detection of duplications for /home/ncombs/Dev/Sonarqube_a_experiment/src/main/python/main_chatgpt_altered.py
04:52:00.446 DEBUG: Detection of duplications for /home/ncombs/Dev/Sonarqube_a_experiment/src/main/python/main.py
04:52:00.448 DEBUG: Detection of duplications for /home/ncombs/Dev/Sonarqube_a_experiment/src/main/python/TicTacToe.py
04:52:00.450 DEBUG: Detection of duplications for /home/ncombs/Dev/Sonarqube_a_experiment/src/main/java/ticTacToe.java
04:52:00.452 INFO: CPD Executor CPD calculation finished (done) | time=15ms
04:52:00.560 INFO: Analysis report generated in 99ms, dir size=219.8 kB
04:52:00.585 INFO: Analysis report compressed in 25ms, zip size=39.5 kB
04:52:00.586 INFO: Analysis report generated in /home/ncombs/Dev/Sonarqube_a_experiment/.scannerwork/scanner-report
04:52:00.586 DEBUG: Upload report
04:52:00.610 DEBUG: POST 200 http://localhost:9000/api/ce/submit?projectKey=TestSonarqube&projectName=TestSonarqube | time=22ms
04:52:00.613 INFO: Analysis report uploaded in 27ms
04:52:00.614 DEBUG: Report metadata written to /home/ncombs/Dev/Sonarqube_a_experiment/.scannerwork/report-task.txt
04:52:00.614 INFO: ANALYSIS SUCCESSFUL, you can find the results at: http://localhost:9000/dashboard?id=TestSonarqube
04:52:00.614 INFO: Note that you will be able to access the updated dashboard once the server has processed the submitted analysis report
04:52:00.615 INFO: More about the report processing at http://localhost:9000/api/ce/task?id=ae092e7d-d92e-42c5-a3fe-99fc44dbe055
04:52:00.619 DEBUG: Post-jobs : 
04:52:00.629 INFO: Analysis total time: 15.370 s
04:52:00.631 INFO: ------------------------------------------------------------------------
04:52:00.631 INFO: EXECUTION SUCCESS
04:52:00.631 INFO: ------------------------------------------------------------------------
04:52:00.632 INFO: Total time: 16.705s
04:52:00.710 INFO: Final Memory: 48M/154M
04:52:00.710 INFO: ------------------------------------------------------------------------

Blockquote

Hey there.

Seems like you’re doing everything right. Are there specific issues you expect to be raised on the Python code that aren’t being raised?

Thank you very much! It turned out to be a mistake on my part - I was constructing an experiment where I asked ChatGPT to take test Python code and insert smells into it. It modified the code and annotated changes as smells. However, it turned out they were hallucinations. The good news was that I ended up spending a lot of time learning about Sonarqube while trying to debug this!

1 Like

ChatGPT helps me as much as it hurts me too. :smiley: Glad you figured it out. Hope you find some real buggy python code to see the power of SQ!

1 Like