feat(simple_planning_simulator): add new vehicle model with falling down #7651
CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main)
failed
Jun 27, 2024 in 45s
CodeScene PR Check
❌ Code Health Quality Gates: FAILED
- Declining Code Health: 6 findings(s) 🚩
Details
🚩 Declining Code Health (highest to lowest):
- Complex Method sim_model_delay_steer_acc_geared_wo_fall_guard.cpp: SimModelDelaySteerAccGearedWoFallGuard::calcModel
- Complex Conditional simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_initial_state
- Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_input
- Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::initialize_vehicle_model
- Bumpy Road Ahead sim_model_delay_steer_acc_geared_wo_fall_guard.cpp: SimModelDelaySteerAccGearedWoFallGuard::calcModel
- Complex Method simple_planning_simulator_core.cpp: SimplePlanningSimulator::set_initial_state
Annotations
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
SimplePlanningSimulator::set_input increases in cyclomatic complexity from 12 to 13, 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
SimplePlanningSimulator::initialize_vehicle_model increases in cyclomatic complexity from 12 to 13, 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Method
SimplePlanningSimulator::set_initial_state increases in cyclomatic complexity from 9 to 10, 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ Getting worse: Complex Conditional
SimplePlanningSimulator::set_initial_state increases from 1 complex conditionals with 2 branches to 1 complex conditionals with 3 branches, threshold = 2. A complex conditional is an expression inside a branch (e.g. if, for, while) which consists of multiple, logical operators such as AND/OR. The more logical operators in an expression, the more severe the code smell.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ New issue: Complex Method
SimModelDelaySteerAccGearedWoFallGuard::calcModel has a cyclomatic complexity of 12, 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.
codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)
❌ New issue: Bumpy Road Ahead
SimModelDelaySteerAccGearedWoFallGuard::calcModel has 2 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.
Loading