Alex D: fix rclpy.spin no node error
This commit is contained in:
parent
a752ed603e
commit
c1484b58ce
|
@ -22,10 +22,6 @@ import threading
|
||||||
|
|
||||||
def ros_main() -> None:
|
def ros_main() -> None:
|
||||||
rclpy.init()
|
rclpy.init()
|
||||||
try:
|
|
||||||
rclpy.spin()
|
|
||||||
except ExternalShutdownException:
|
|
||||||
pass
|
|
||||||
|
|
||||||
|
|
||||||
app.on_startup(lambda: threading.Thread(target=ros_main).start())
|
app.on_startup(lambda: threading.Thread(target=ros_main).start())
|
||||||
|
|
Loading…
Reference in New Issue