[Rock-dev] [rock] #174: Roles are missing after an as_plan call on compositions

rock noreply at opendfki.de
Tue May 29 16:35:20 CEST 2012


#174: Roles are missing after an as_plan call on compositions
--------------------------+-----------------------------------
 Reporter:  Chris Müller  |      Owner:  rock-dev-mailing-list
     Type:  defect        |     Status:  new
 Priority:  normal        |  Milestone:
Component:  base          |   Keywords:
--------------------------+-----------------------------------
 Assume the following the composition:

 composition "test"
   add Srv::Data, :as => "data"
 end

 It's currently not possible to define a data_reader for any services
 within the planning interface due to the following issue:

 methods(:test) do
    Cmp::Test.as_plan.script do
        data_reader "data", ["data", "port_name"]

        emit ...
    end
 end

 Trying to execute this method, we will get an error message of:

 16:29:13.358 (Roby simulation)
 /home/chris/repos/avalon/tools/roby/lib/roby/relations/dependency.rb:101:in
 `child_from_role': Orocos::RobyPlugin::Compositions::Test:0x6131400{}[]
 has no child with the role 'data'. Existing roles are  (ArgumentError)

 This message indicates that the generated Task from Cmp::Test.as_plan call
 doesn't know any roles and this conflicts with the role / task search in
 the execution process.

 Cmp::Test.as_plan.children returns an empty array.

-- 
Ticket URL: <http://rock.opendfki.de/ticket/174>
rock <http://rock.opendfki.de>
rock: the robot construction kit


More information about the Rock-dev mailing list