Reputation: 384
So I want use Leaks to find the leaks in my app. In Xcode, I go to "Product" and then hit "Profile". In Instruments I select Leaks and it starts. My app is starting and Leaks is running. But just as soon as my app is finished starting and I can use it, Leaks stops.
Is there anybody else with the same problem or maybe knows how to fix this?
Upvotes: 8
Views: 3845
Reputation: 13429
clean project build folder, close XCode IDE and clean MAC Os caches then it should work. if it's an iOS project you have to delete app from simulator/device before re compile it.
Upvotes: 1
Reputation: 4545
That was my case. If you're using a real device, make sure you're using a valid provisioning profile (development provisioning profile) and that the device is included in the profile. More detailed explanation here.
Upvotes: 0
Reputation: 492
If you use Cocoapods, be sure, you have unchecked Run script only when installing
in Target > Build Phases > [CP] Embedded Pods Framework. Checked this option caused same problem for me.
Upvotes: 0
Reputation: 11
The Leaks instrument seems to close after the app receives lot of memory warnings. Closing all background applications helps.
Upvotes: 1
Reputation: 58448
I've seen this happen when an incorrect provisioning profile is used when building the app and running on a physical device.
You shouldn't see this kind of error when running it in the simulator - it should work as intended. If you're using the simulator in this situation and are you still seeing this behaviour, I would encourage you to go to http://bugreport.apple.com and file a bug regarding this issue, giving as much detail as you possibly can.
If you're using a physical device, ensure you're using a valid provisioning profile and certificate/key pair and that the device is included in the profile.
Upvotes: 0
Reputation: 611
I would chose a development profile for all release,debug modes, clean the simulator, clean xcode ,then i would launch instruments
Upvotes: 1