Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(trajectory_follower): publsih control horzion #8977

Merged
merged 7 commits into from
Nov 14, 2024

rename to ~/debug/control_cmd_horizon

73858be
Select commit
Loading
Failed to load commit list.
Merged

feat(trajectory_follower): publsih control horzion #8977

rename to ~/debug/control_cmd_horizon
73858be
Select commit
Loading
Failed to load commit list.
CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main) failed Nov 14, 2024 in 38s

CodeScene PR Check

Code Health Quality Gates: FAILED

Change in average Code Health of affected files: -0.09 (7.07 -> 6.98)

  • Declining Code Health: 4 findings(s) 🚩

View detailed results in CodeScene

Details

🚩 Declining Code Health (highest to lowest):

  • Large Assertion Blocks test_mpc.cpp
  • Complex Method controller_node.cpp: Controller::mergeLatLonHorizon
  • Complex Method controller_node.cpp: Controller::Controller
  • Bumpy Road Ahead controller_node.cpp: Controller::mergeLatLonHorizon

Annotations

Check notice on line 1 in control/autoware_mpc_lateral_controller/src/mpc.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

ℹ Getting worse: Overall Code Complexity

The mean cyclomatic complexity increases from 5.11 to 5.16, 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 140 in control/autoware_mpc_lateral_controller/src/mpc.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

ℹ Getting worse: Excess Number of Function Arguments

MPC::calculateMPC increases from 5 to 6 arguments, threshold = 4. This function has too many arguments, indicating a lack of encapsulation. Avoid adding more arguments.

Check warning on line 222 in control/autoware_mpc_lateral_controller/test/test_mpc.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

❌ New issue: Large Assertion Blocks

The test suite contains 8 assertion blocks with at least 4 assertions, threshold = 4. This test file has several blocks of large, consecutive assert statements. Avoid adding more.

Check warning on line 365 in control/autoware_trajectory_follower_node/src/controller_node.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

❌ New issue: Complex Method

Controller::mergeLatLonHorizon 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 warning on line 108 in control/autoware_trajectory_follower_node/src/controller_node.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

❌ New issue: Complex Method

Controller::Controller 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 warning on line 365 in control/autoware_trajectory_follower_node/src/controller_node.cpp

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (main)

❌ New issue: Bumpy Road Ahead

Controller::mergeLatLonHorizon 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.