-
Notifications
You must be signed in to change notification settings - Fork 636
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash report from Dynamo 2.19.3.6394 - UnwrapElement() #15569
Comments
tracked internally https://jira.autodesk.com/browse/DYN-7785 |
Hi @Aaron12Powers ! Is unwrapping custom classes something that has worked for you in the past? A different version of Dynamo, or was it in IronPython, same version? |
Hey @twastvedt, These are my results of some limited testing
Revit 2022 - First year CPython3 was included Revit 2024 - Version I typically use day to day |
Thanks for the detail! Yep, I can reproduce that. We'll add it to the list! |
Issue Description
Please fill in the following information to help us reproduce the issue:
Revit/Dynamo Fully crashing (Without crash window or any form of warning) when passing custom class instances into "UnwrapElement()" within a Python Script Node running the CPython3 engine
For years, Ive handled Python Node Inputs by running everything through a "UnwrapElement()" method as a sort of catch all (probably not the best practice admittedly). This never caused issues and I've assumed it functioned as a passthrough if the arguments were not Revit Elements.
This includes, lists, dictionaries, and custom class instances which may contain elements as member properties within them.
The Custom Classes is where I believe things have changed. Whenever I pass in an instance of a custom class dynamo spins for ~10 seconds then completely closes everything associated to the Revit Window.
Dynamo version
Dynamo:
2.19.3.6394
Operating system
OS:
Microsoft Windows NT 10.0.19045.0
What did you do?
I passed a custom class instance containing a Revit Element as one of it's properties into the "UnwrapElement()" method
I was able to replicate this very simply with the following code:
`
class TestObj:
def init(self):
self.Name = "Test"
UnwrapElement(TestObj())
`
What did you expect to see?
I expected UnwrapElement to either return the same instance I passed into it with no change, or to throw an argument error from the python node if the argument types have been restricted.
What did you see instead?
Full Revit/Dynamo Crash without error message/window.
What packages or external references (if any) were used?
Python Script Node - CPython3
Stack Trace
No Crash Window was Produced
CLR:
4.0.30319.42000
The text was updated successfully, but these errors were encountered: