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

refactor(hesai_hw_interface): remove mention of Velodyne sensors in Hesai code #100

Merged
merged 1 commit into from
Nov 29, 2023

Conversation

mojomex
Copy link
Collaborator

@mojomex mojomex commented Nov 28, 2023

NebulaModelToHesaiModelNo was explicitly handling Velodyne models, while it should really just handle everything that is not Hesai the same. Because of this, PR #77 and future sensor additions cause warnings in this piece of code (enum value XYZ not handled).

PR Type

  • Improvement

Description

The function on question now has a generic default case for any non-Hesai sensors. Functionally it is exactly the same as before.

Review Procedure

Confirm there are no build warnings like "Enum value XYZW not handled in switch statement", confirm in the diff that the code is equivalent.

Pre-Review Checklist for the PR Author

PR Author should check the checkboxes below when creating the PR.

  • Assign PR to reviewer

Checklist for the PR Reviewer

Reviewers should check the checkboxes below before approval.

  • Commits are properly organized and messages are according to the guideline
  • (Optional) Unit tests have been written for new behavior
  • PR title describes the changes

Post-Review Checklist for the PR Author

PR Author should check the checkboxes below before merging.

  • All open points are addressed and tracked via issues or tickets

CI Checks

  • Build and test for PR: Required to pass before the merge.

`NebulaModelToHesaiModelNo` was explicitly handling Velodyne models, while it should really just handle everything that is `not Hesai` the same. Because of this, PR tier4#77 and future sensor additions cause warnings in this piece of code (enum value XYZ not handled).
@mojomex mojomex requested review from amc-nu and drwnz November 28, 2023 06:08
@mojomex mojomex self-assigned this Nov 28, 2023
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (71e7d0e) 8.29% compared to head (0f22ed8) 3.96%.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff            @@
##            main    #100      +/-   ##
========================================
- Coverage   8.29%   3.96%   -4.33%     
========================================
  Files         87      27      -60     
  Lines       8455    5952    -2503     
  Branches     852     463     -389     
========================================
- Hits         701     236     -465     
+ Misses      7179    5304    -1875     
+ Partials     575     412     -163     
Flag Coverage Δ
differential 3.96% <ø> (?)
total ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@drwnz drwnz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@drwnz drwnz merged commit 7e28d15 into tier4:main Nov 29, 2023
6 checks passed
@mojomex mojomex deleted the fix-hesai-model-switch branch November 29, 2023 09:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants