Why do I get instruments - “Target failed to run”?

2019-02-05 11:36发布

Target failed to run: Remote exception encountered: Faild to get task for pid 3103

Target failed to run

I'm running iPhone OS 3.1.3 on the device and I can run my App in debug mode on the device.

I downloaded and installed the xcode_3.2.2_and_iphone_sdk_3.2_final.dmg twice, without any luck.

6条回答
狗以群分
2楼-- · 2019-02-05 11:48

I got the same issue when I switched to XCode 4 and I solved it by setting my release code-signing profile to my development profile instead of the app store profile that was previously set. Indeed, Xcode 4 profiles your app using the release build by default.

查看更多
不美不萌又怎样
3楼-- · 2019-02-05 11:53

Hey.
There can also be some other issues.

Provisioning Profile.
From Apple documentation: For your protection, the instrument does not allow you to process any application that is not code-signed with your provisioning profile. This includes any copy that has been downloaded from the iTunes App Store.

Device.
Instrumetns UIAutomation doesn't work on iPhone 3G, only 3Gs, 4.

Sadly support for instruments is bad. Apple doesn't seem to put much attention to it.

查看更多
▲ chillily
4楼-- · 2019-02-05 12:03

To answer my own question:

I have two applications installed on my device with the same name resp. the same Bundle display name: Doublemill. Since they have different bundle identifiers, the debugger can deal with that, however Instruments seems to be confused.

查看更多
男人必须洒脱
5楼-- · 2019-02-05 12:05

FYI for those running from the command line and getting the same issue, you have to use the fully qualified path to the application or instruments will blow up (with a relative path). That was a good waste of a couple hours tracking that down.

查看更多
SAY GOODBYE
6楼-- · 2019-02-05 12:08

For those of you having this issues set your "Code Signing Identity" to IOS Developer, see below.

enter image description here

查看更多
我欲成王,谁敢阻挡
7楼-- · 2019-02-05 12:11

In my case, I using distribute provisioning profile in Release, change to development provisioning profile will fix that.

查看更多
登录 后发表回答