mirror of
https://github.com/moveit/moveit_task_constructor.git
synced 2025-11-04 14:49:57 +08:00
enable introspection only if ROS was initialized
This commit is contained in:
parent
bd60e6f65d
commit
35b35cc17e
@ -55,8 +55,9 @@ Task::Task(const std::string& id, ContainerBase::pointer &&container)
|
|||||||
{
|
{
|
||||||
// monitor state on commandline
|
// monitor state on commandline
|
||||||
//addTaskCallback(std::bind(&Task::printState, this, std::ref(std::cout)));
|
//addTaskCallback(std::bind(&Task::printState, this, std::ref(std::cout)));
|
||||||
// enable introspection by default
|
// enable introspection by default, but only if ros::init() was called
|
||||||
enableIntrospection(true);
|
if (ros::isInitialized())
|
||||||
|
enableIntrospection(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
planning_pipeline::PlanningPipelinePtr
|
planning_pipeline::PlanningPipelinePtr
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user