Complete UI lock out in R8, possibly from R7 GH python components

OK Guys,

Bit of a strange one.

Can’t really discuss too much detail as this this relates to the ‘secret sauce’ in my code.

But this is how I can frame it.

I have been using 3x GH Record components holding txt and curve data up to 500 steps deep in a setup with 2x Anemone nested loops (yep it is as weird as it sounds)

What I have noticed since this code was written was a memory leak - when this looping is running the memory usage of Rhino just ticks up, 3GB to 10+GB over the course of 30 min or so.

Stopping and restarting the code (which resets the record components to empty) doesn’t clean up the memory usage and it will tick up from where it left off.

As you might expect this code will slow to a crawl after a period of time.

Until now I’ve not looked into it very much as the code was working.

Well this week I’ve looked into it and what might be leaking memory like a sieve.

First port of call was the GH Record components, which I’ve replaced with some “roll my own” GH Python code using a sticky_dict. This wasn’t the easiest as I need to save “groups” of curves as part of the process.

Well, I got this to work on R7 and the memory leak seems to have been solved. The memory usage tops out at about 3GB and will drop back as the process stores less data/will drop right off if I clear these GH Python sticky_dict.

Now all running GREAT on R7 and has improved the overall performance of my code a LOT BUT load it into R8 and as soon as I run this new code the Rhino/GH/Custom UI locks up. I can see my code running fine in the Rhino viewport but I can’t get control back.

The only way to kill it is from Task Manager.

I will try to produce a ‘something’ that shows the issue. But before then any ideas brains trust?



Is it wrapped into a cluster? There was a bug report that clusters don‘t free the memory properly in RH8.

Hi Tom,

No clusters in this code, I was using a strange “Advanced Group” component/cluster from FabTools but have dropped that in favour of some serialize components.

The strange thing is I have second copy of the code base cut down for some users and that runs fine with the new Python based record components. This UI lockup is just weird…



OK, this is starting to F me off, like I said I have two versions of my code, one works FINE on both R7 and R8, the other works fine in R7 and completely hangs the UI in R8. I have been able to esc-esc-esc on the GH canvas to get out of the hang, but gone over the two versions of the code block by block (even copied in the working version) and can’t find ANY differences.

Just when I thought I was getting over my R8 problems…


OK - I don’t know WHY this worked but I went back two days in my ‘production’ source tree and copied the new code from the working version into the old source and the the bug vanished.

Chasing my tail for a whole day and that fixed it…