we have a Rhino 6 plugin and one of our users reported a Rhino crash when they move objects around (with gumball or otherwise). I was not able to reproduce this with Rhino 7.
I’ve tracked it down to a crash in the GC finalizer thread when we try to access mesh properties such as Vertices, Normals or Faces. The user also reported that this issue seems to get worse the bigger the project is. As the issue comes from the finalizer it’s not 100% reproducible but can definitely be triggered after moving objects around for a minute or two.
In general, what we do in our plugin is that we are subscribed to events such as RhinoDoc.AddRhinoObject. We collect all the added/changed/deleted objects and then process those changes in the next RhinoApp.Idle.
Part of that processing is reading the mesh from newly added objects and this is where the crash occurs.
The objects that we are accessing at this point are all valid (via the IsValid check) and not disposed.
Here is a mini crashdump, attach with Mixed. The exception is in the GC Finalizer Thread and our plugin is trying to access the MeshFaceList in the Main Thread.
Rhino crash after moving objects.zip (674.7 KB)
Can we avoid this crash in any way? Is this there a known issue for this case?