Acceleo : Invalid result when querying Capella derived features

I created an Acceleo template in Capella studio 1.2.0. My goal is to gather some Capella model information into a script.
My template works well for direct features
(like PhysicalActor name)
But the program returns an invalid result for all the derived features I try to query
(like PhysicalActor allocatedFunctions)
ei :
This template returns the following script:
Physical actors**
1 : User
2 : invalid
1 : Radio Transmitter
2 : invalid
1 : PA 3
2 : invalid
1 : External power
2 : invalid
I also tried Acceleo Query and java service wrapped to Acceleo. I experienced the same issue.
Is there any mean to query Capella derived features?

Hi Christophe,
try this one:

Thanks Jakub for your Help
i tried your code, it works well.
Do you know why some derived features work and some other return an invalid result ?
I looked at the derived features getter implementation. The code refer to a helper function so it is difficult to see, how and where each getter has been implemented.

Hi Christophe,
great that it works for you. Unfortunately no idea why it’s like that - someone familiar with Ecore could perhaps help here. I’m still very new to EMF.