|
| 1 | +# ============================================================================= |
| 2 | +# SonarCloud Automatic Analysis configuration |
| 3 | +# https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/automatic-analysis/ |
| 4 | +# |
| 5 | +# SonarCloud's automatic analysis (GitHub App, no CI workflow) reads THIS file. |
| 6 | +# Wildcard patterns are NOT supported here, so all exclusion paths must be |
| 7 | +# listed explicitly. |
| 8 | +# ============================================================================= |
| 9 | + |
| 10 | +sonar.projectKey=nanotaboada_python-samples-fastapi-restful |
| 11 | +sonar.organization=nanotaboada |
| 12 | +sonar.projectName=python-samples-fastapi-restful |
| 13 | + |
| 14 | +sonar.sources=databases,models,routes,schemas,services,tools,main.py |
| 15 | +sonar.tests=tests |
| 16 | + |
| 17 | +# ============================================================================= |
| 18 | +# Global exclusions |
| 19 | +# Standalone seed scripts excluded from analysis. |
| 20 | +# ============================================================================= |
| 21 | + |
| 22 | +sonar.exclusions=\ |
| 23 | + tools/seed_001_starting_eleven.py,\ |
| 24 | + tools/seed_002_substitutes.py |
| 25 | + |
| 26 | +# ============================================================================= |
| 27 | +# Coverage exclusions |
| 28 | +# Mirrors codecov.yml ignore list — focus on routes/, services/ |
| 29 | +# ============================================================================= |
| 30 | + |
| 31 | +sonar.coverage.exclusions=\ |
| 32 | + databases/__init__.py,\ |
| 33 | + databases/player_database.py,\ |
| 34 | + models/__init__.py,\ |
| 35 | + models/player_model.py,\ |
| 36 | + schemas/__init__.py,\ |
| 37 | + schemas/player_schema.py,\ |
| 38 | + tools/seed_001_starting_eleven.py,\ |
| 39 | + tools/seed_002_substitutes.py,\ |
| 40 | + tests/__init__.py,\ |
| 41 | + tests/conftest.py,\ |
| 42 | + tests/player_stub.py,\ |
| 43 | + tests/test_main.py,\ |
| 44 | + main.py |
| 45 | + |
| 46 | +# ============================================================================= |
| 47 | +# Duplicate code (CPD) exclusions |
| 48 | +# Automatic analysis does not support wildcard patterns, so each file is |
| 49 | +# listed explicitly. |
| 50 | +# |
| 51 | +# player_stub.py — test fixture; parallel field assignments by design. |
| 52 | +# seed scripts — sequential insert calls are intentionally repetitive. |
| 53 | +# ============================================================================= |
| 54 | + |
| 55 | +sonar.cpd.exclusions=\ |
| 56 | + tests/player_stub.py,\ |
| 57 | + tools/seed_001_starting_eleven.py,\ |
| 58 | + tools/seed_002_substitutes.py |
0 commit comments