CodeScene PR Check
✅ Code Health Quality Gates: OK
- Improving Code Health: 5 findings(s) ✅
Details
✅ Improving Code Health:
- Overall Code Complexity scene.cpp
- Complex Method scene.cpp: BlindSpotModule::generateBlindSpotPolygons
- Complex Method scene.cpp: BlindSpotModule::isCollisionDetected
- Bumpy Road Ahead scene.cpp: BlindSpotModule::generateBlindSpotPolygons
- Deep, Nested Complexity scene.cpp: BlindSpotModule::cutPredictPathWithDuration
Annotations
Check notice on line 133 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ Getting worse: Complex Method
BlindSpotModule::modifyPathVelocityDetail increases in cyclomatic complexity from 9 to 14, threshold = 9. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.
Check notice on line 693 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Complex Method
BlindSpotModule::generateBlindSpotPolygons is no longer above the threshold for cyclomatic complexity. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.
Check notice on line 494 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Complex Method
BlindSpotModule::isCollisionDetected is no longer above the threshold for cyclomatic complexity. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.
Check notice on line 681 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ New issue: Complex Method
BlindSpotModule::generateBlindSpotLanelets has a cyclomatic complexity of 22, threshold = 9. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.
Check notice on line 693 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Bumpy Road Ahead
BlindSpotModule::generateBlindSpotPolygons is no longer above the threshold for logical blocks with deeply nested code. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.
Check notice on line 681 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ New issue: Bumpy Road Ahead
BlindSpotModule::generateBlindSpotLanelets has 4 blocks with nested conditional logic. Any nesting of 2 or deeper is considered. Threshold is one single, nested block per function. The Bumpy Road code smell is a function that contains multiple chunks of nested conditional logic. The deeper the nesting and the more bumps, the lower the code health.
Check notice on line 1 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ Getting better: Overall Code Complexity
The mean cyclomatic complexity decreases from 4.78 to 4.60, threshold = 4. This file has many conditional statements (e.g. if, for, while) across its implementation, leading to lower code health. Avoid adding more conditionals.
Check notice on line 412 in planning/behavior_velocity_blind_spot_module/src/scene.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Deep, Nested Complexity
BlindSpotModule::cutPredictPathWithDuration is no longer above the threshold for nested complexity depth