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

Fix potential deadlock and wait until service is available #87

Merged
merged 2 commits into from
Mar 4, 2025

Conversation

belalhmedan90
Copy link
Contributor

  1. Replace rate.sleep() with rclpy.spin_once(self._node, timeout_sec=1.0) to avoid sleeping forever.
  2. Ensure Start Joint States Are present.
  3. Wait for the ROS2 Services to make sure they are available.

Signed-off-by: Andrej Orsula <[email protected]>
Copy link
Owner

@AndrejOrsula AndrejOrsula left a comment

Choose a reason for hiding this comment

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

Thank you, @belalhmedan90, for your contribution!

@AndrejOrsula AndrejOrsula changed the title Update moveit2.py Fix potential deadlock and wait until service is available Mar 4, 2025
@AndrejOrsula AndrejOrsula merged commit 1f030f6 into AndrejOrsula:devel Mar 4, 2025
2 checks passed
andrewbowman23 added a commit to andrewbowman23/pymoveit2 that referenced this pull request Mar 4, 2025
andrewbowman23 added a commit to andrewbowman23/pymoveit2 that referenced this pull request Mar 4, 2025
andrewbowman23 added a commit to andrewbowman23/pymoveit2 that referenced this pull request Mar 4, 2025
Can't use rclpy.spin unless rclpy is imported.
Also, wait_until_exectued use of spin was incorrect.
andrewbowman23 added a commit to andrewbowman23/pymoveit2 that referenced this pull request Mar 4, 2025
Can't use rclpy.spin unless rclpy is imported.
Also, wait_until_executed use of spin was incorrect.
AndrejOrsula added a commit that referenced this pull request Mar 4, 2025
* Fix rclpy import and spin issues from (#87)

Can't use rclpy.spin unless rclpy is imported.
Also, wait_until_executed use of spin was incorrect.

* Apply pre-commit suggestions

Signed-off-by: Andrej Orsula <[email protected]>

---------

Signed-off-by: Andrej Orsula <[email protected]>
Co-authored-by: Andrej Orsula <[email protected]>
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.

2 participants