-
Notifications
You must be signed in to change notification settings - Fork 740
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
Fix retain cycle #1826
Fix retain cycle #1826
Conversation
@gpambrozio: Thank you for submitting a pull request! Before we can merge it, you'll need to sign the Apollo Contributor License Agreement here: https://contribute.apollographql.com/ |
Ohhhh, that's interesting - so moving it to an |
Thanks so much for this fix! Next we need to test if this actually fixes #516 or if there is more work to do there. |
@AnthonyMDev any idea of when this will make it into a release? I need this for my project and would love to not have to point to my fork. |
So, we've had some transient test failures in our CircleCI builds recently that I have been trying to track down, but haven't been able to repro locally. The test failures are always in As soon as we can figure out what is causing this and fix that issue, I'll release a new version. I'm working on something now, but it's a shot in the dark. |
@AnthonyMDev I had test issues and this line is what solved it as you need a new runloop to clean up memory. It might be that CI needs more time. On our project we have different timeouts for ci and local because our ci uses virtual machines and those are very slow and unreliable. |
Thanks for the info. That might help! Looking into it currently! |
I think I just fixed this more elegantly by creating a "Busy Assertion". I just created an It's included in this PR #1830 I'll talk to @designatednerd about pushing a release tomorrow, or at least sometime this week, to include this fix! Thanks @gpambrozio |
@gpambrozio This release has been pushed! |
This change turned a weak reference into a strong one and created a cycle that might keep all watch objects in memory.
This pull request adds a test that fails without my fix and succeeds otherwise. Test was pushed in a first, separate commit to make it easier to check out the branch at that commit and see the error.
This might be related to this story