What is the correct way to serialize data for rpc in grasshopper


I’m running into a seemingly simple problem where I am unable to pass a compas mesh to an rpc proxy:
In grasshopper, I need to convert a compas mesh to a trimesh datastructure (trimsh) but it fails in a cryptic way (Fault, see screenshot).


It looks similar (at least on the surface) to 'Fault' in rpc call

The rpc works (I can call functions as long as it takes simple arguments (python base types), but can’t pass any compas objects.

What am I missing for the correct serialization of a compas mesh?

Thanks in advance!


(PS: compas version 1.17.0, Rhino 7 SR 24)

what is the type of the return value of schema.shapes.mesh_compas_to_trimesh?

:bulb: thanks! rooky mistake…
Not that it is clearly stated in the docs that you need to both serialize and de-serialize