RhinoDoc.Groups.GroupMembers(int index) does not work with headless doc

Hi,

I am loading a RhinoDoc headlessly from a Python script in Rhino 8 on Windows, using RhinoDoc.OpenHeadless(). When calling headlessDoc.Groups.GroupMembers() with an index of a group that I know exists in the headless document, it returns nothing. If I call it with the index of a group that exists in the current ActiveDoc, then it returns that.

Other similar calls such as GroupObjectCount(), GroupName(), and FindIndex() return the correct information.

It seems like GroupMembers() is using the ActiveDoc instead of the one it is supposed to…

Is this a known bug or am I using something incorrectly?

Thanks!

EDIT: I tried using headlessDoc.Objects.FindByGroup() and this seems to give me the correct objects. Is there a particular difference between the two methods (other than the first not working :wink: ) or is one deprecated?

Hi @tom_svilans,

Just a bug. I’ll get it tuned up.

– Dale

1 Like

Amazing - thanks, Dale!