UI loses reference to buttons
cadop opened this issue · 2 comments
When changing between units or setting the directory, the UI maintains its reference. However, when using the preview button, it seems that the UI is lost, and after it calculates the joint configuration, changing any of the other dropdowns does not get registered.
I suspect it could be a handler
issue. The other possibility is that something is reloading the autodesk core which ends up overwriting its callbacks to the UI we implemented. At the moment not sure how to debug this as the program already terminates early from the callback.
Seems that this line/function is the culprit:
https://github.com/cadop/fusion360xml/blob/d37a15dced5be4b859106be6cdb904753347150b/Descriptor/core/parser.py#L115
It seems like, somehow its changes the root occurrence in the recursion. Not sure how yet.
Actually the problem is worse and more difficult to figure out. I thought this was the cause, but that was simply because my breakpoint was there. It seems like if I put a breakpoint in debug mode inside of the code, it will keep the UI reference, but if it runs on its own, it gets lost.
really no idea how to fix it