Closed ipa-nhg closed 4 years ago
The metamodel has to be updated to support the actions, this will be done on a separated PR as this one separately can't break HAROS (the functions are not been called).
Good idea. That is probably more manageable than a monolithic PR. :+1:
The functions had been tested on a separated plugin using the following lines (that for HAROS have to be added/called here https://github.com/git-afsantos/haros/blob/master/haros/extractor.py#L802-L814):
for call in (CodeQuery(gs).all_calls.where_name("SimpleActionServer").get()): name = self._extract_action(call) action_type = self._extract_action_type(call) for call in (CodeQuery(gs).all_calls.where_name("SimpleActionClient").get()): name = self._extract_action(call) action_type = self._extract_action_type(call)
It is unlikely that there are any more SimpleActionClient
s in user code besides the one from actionlib
, but, out of curiosity, is there any reason for not including where_result("actionlib::SimpleActionClient")
in the query? Is this related to the issue below?
Still some cases for Action Clients are not supported, for example when the ActionClient is declared with typdef.
Probably to support this cases bonsai has also to be updated.
I will give it a go to see what is going on.
Probably to support this cases bonsai has also to be updated.
Yes, seems like it. Doing cppobj.result
returns the typedef
type, and not the original one.
I have updated bonsai
so that many C++ objects now have an additional canonical_type
.
For reference: https://github.com/git-afsantos/bonsai/issues/14
The metamodel has to be updated to support the actions, this will be done on a separated PR as this one separately can't break HAROS (the functions are not been called).
The functions had been tested on a separated plugin using the following lines (that for HAROS have to be added/called here https://github.com/git-afsantos/haros/blob/master/haros/extractor.py#L802-L814):
Still some cases for Action Clients are not supported, for example when the ActionClient is declared with typdef. i.e. :
Probably to support this cases bonsai has also to be updated.