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

Cflib backend closing error #559

Open
knmcguire opened this issue Sep 3, 2024 · 0 comments
Open

Cflib backend closing error #559

knmcguire opened this issue Sep 3, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@knmcguire
Copy link
Collaborator

When Crazyswarm2 cflib backend server is closed, there is first a whole bunch of errors (like a hundred or so) of these:

[crazyflie_server.py-1] Traceback (most recent call last):
[crazyflie_server.py-1]   File "/home/knmcguire/Workspaces/crazyswarm2_ws/venv/lib/python3.12/site-packages/cflib/crazyflie/__init__.py", line 415, in run
[crazyflie_server.py-1]     cb.callback(pk)
[crazyflie_server.py-1]   File "/home/knmcguire/Workspaces/crazyswarm2_ws/venv/lib/python3.12/site-packages/cflib/crazyflie/log.py", line 632, in _new_packet_cb
[crazyflie_server.py-1]     block.unpack_log_data(logdata, timestamp)
[crazyflie_server.py-1]   File "/home/knmcguire/Workspaces/crazyswarm2_ws/venv/lib/python3.12/site-packages/cflib/crazyflie/log.py", line 348, in unpack_log_data
[crazyflie_server.py-1]     self.data_received_cb.call(timestamp, ret_data, self)
[crazyflie_server.py-1]   File "/home/knmcguire/Workspaces/crazyswarm2_ws/venv/lib/python3.12/site-packages/cflib/utils/callbacks.py", line 54, in call
[crazyflie_server.py-1]     cb(*args)
[crazyflie_server.py-1]   File "/home/knmcguire/Workspaces/crazyswarm2_ws/install/crazyflie/lib/crazyflie/crazyflie_server.py", line 516, in _log_pose_data_callback
[crazyflie_server.py-1]     self.swarm._cfs[uri].logging["pose_publisher"].publish(msg)
[crazyflie_server.py-1]   File "/opt/ros/jazzy/lib/python3.12/site-packages/rclpy/publisher.py", line 70, in publish
[crazyflie_server.py-1]     self.__publisher.publish(msg)
[crazyflie_server.py-1] rclpy._rclpy_pybind11.RCLError: Failed to publish: publisher's context is invalid, at ./src/rcl/publisher.c:423

Probably has something to do with the publishers not being closed properly when doing ctrl+c

@knmcguire knmcguire added the bug Something isn't working label Sep 3, 2024
@knmcguire knmcguire self-assigned this Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant