-
Notifications
You must be signed in to change notification settings - Fork 2
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
Memory freeing #87
Comments
Del operator only works if a reference goes out of scope. Reference to an doh objext does not go out of scope until it main window still has doh reference. Virtually same topic as #56 |
You are right but I doesn't change anything even if you set all this variables to None, memory is not released. Check it with memory profiler. |
Right, it doesnt now if the widgets are still running, we are just removing reference from doh which would be still there after widget is destroyed. |
Closer but still not there :P |
Of course problem is connected with deleting only reference |
What do you mean? I think I dont get it. What I meant is that we merely nullify reference in doh objects not outside. If reference exists outside then it should, but since doh is sort of global it must be cleaned manually, but that doest equal data deletion |
I think you haven't checked if function removeDataObject is working. Python has garbage collector that deletes object when there is 0 refs, but another thing is that Python releases this memory when it wants not when we want that. Using del operator for example is considered bad practice. If we truly want to delete some object from mem, we should restart program or, delete all references to object and wait until it's deleted (It may never happen). I don't think there is proper solution for that because Python seems to be smarter. Fortunately it seems that garbage collector is doing good job at runtime end.
The text was updated successfully, but these errors were encountered: