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

Small changes #4427

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

xianglunkai
Copy link
Contributor


Basic Info

Info Please fill out this column
Ticket(s) this addresses (add tickets here #1)
Primary OS tested on (Ubuntu, MacOS, Windows)
Robotic platform tested on (Steve's Robot, gazebo simulation of Tally, hardware turtlebot)
Does this PR contain AI generated software? (No; Yes and it is marked inline in the code)

Description of contribution in a few bullet points

Description of documentation updates required from your changes


Future work that may be required in bullet points

For Maintainers:

  • Check that any new parameters added are updated in docs.nav2.org
  • Check that any significant change is added to the migration guide
  • Check that any new features OR changes to existing behaviors are reflected in the tuning guide
  • Check that any new functions have Doxygen added
  • Check that any new features have test coverage
  • Check that any new plugins is added to the plugins page
  • If BT Node, Additionally: add to BT's XML index of nodes for groot, BT package's readme table, and BT library lists

}
}
}

// Take average
effort /= stall_joint_names_.size();
velocity /= stall_joint_names_.size();
if (match_count > 0) {
Copy link
Member

Choose a reason for hiding this comment

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

Is this just to avoid a divide by zero issue? If so, we could just have a bool instead which would be more intuitive unless we're going to use the count rather than the size (or check that count == size or something to check we have all the stuff needed)

Copy link
Contributor

Choose a reason for hiding this comment

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

If this is really targeting a divide by zero, we probably should update the configure() to not create the subscriber if stall_joint_names_ is empty() - it already prints an error, but there is no reason to have the subscriber run the callback if there are no names to match

@SteveMacenski
Copy link
Member

Please sign off with DCO! If you click on the job, it'll tell you how to ammend your commit for it (-s)

@SteveMacenski
Copy link
Member

@xianglunkai can you update the PR as we asked in the review so we can merge this? 😄

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