feat(behavior_velocity): add the option to keep the last valid observation #6036
CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main)
succeeded
Jan 10, 2024 in 53s
CodeScene PR Check
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 2 findings(s) ✅
- Affected Hotspots: 1 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Details
✅ Improving Code Health:
- Lines of Code in a Single File scene_intersection.cpp 🔥
- Complex Method scene_intersection.cpp: isGreenSolidOn 🔥
Annotations
Check notice on line 1 in planning/behavior_velocity_intersection_module/src/scene_intersection.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ Getting better: Lines of Code in a Single File
The lines of code decreases from 2852 to 2850, improve code health by reducing it to 1000. The number of Lines of Code in a single file. More Lines of Code lowers the code health.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
✅ No longer an issue: Complex Method
isGreenSolidOn 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ New issue: Complex Method
IntersectionModule::isGreenSolidOn has a cyclomatic complexity of 9, 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 1 in planning/behavior_velocity_intersection_module/src/scene_intersection.cpp
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
ℹ Getting worse: Primitive Obsession
The ratio of primitive types in function arguments increases from 33.33% to 33.72%, threshold = 30.0%. The functions in this file have too many primitive types (e.g. int, double, float) in their function argument lists. Using many primitive types lead to the code smell Primitive Obsession. Avoid adding more primitive arguments.
Loading