Skip to content

feat(map_loader): add format_version validation

CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (main) succeeded May 20, 2024 in 42s

CodeScene PR Check

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩

View detailed results in CodeScene

Details

🚩 Declining Code Health (highest to lowest):

  • Complex Conditional lanelet2_map_loader_node.cpp: Lanelet2MapLoaderNode::on_map_projector_info

Annotations

Check notice on line 108 in map/map_loader/src/lanelet2_map_loader/lanelet2_map_loader_node.cpp

See this annotation in the file changed.

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

ℹ New issue: Complex Method

Lanelet2MapLoaderNode::on_map_projector_info has a cyclomatic complexity of 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.

Check warning on line 87 in map/map_loader/src/lanelet2_map_loader/lanelet2_map_loader_node.cpp

See this annotation in the file changed.

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

❌ New issue: Complex Conditional

Lanelet2MapLoaderNode::on_map_projector_info has 1 complex conditionals with 2 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.