Device denied the launch request error

I am simply trying to run my app on my iPad through lightning cable but I am getting this strange error:


Could not launch "[App Name]"

[Device name] denied the launch request


I have looked all over the internet for an answer to this but cant seem to find a good solid fix.


I have tried everything from deleting the app on my iPad to cleaning the project to restarting many times but nothing will work. Right now I am running Xcode 9 beta so I tried switching to Xcode 8.3.3 and testing it there. I get a different error:


Could not launch "[App Name]"

process launch failed: Unspecified



Next, I tried doing it on the simulator to see if it was any different. The outcome was a continuous loop of the app opening and crash, then opening again, and crashing again. After about five minutes of this loop, I got this error:


The request to open "com.hp.Goal-Tapper" failed.

The request was denied by service delegate (SBMainWorkspace) for reason: Unspecified.


Does anyone know how to fix this? I am a beginner at Xcode and swift so I won't know very complicated things. Thanks in advance. Any help is appreciated.

Accepted Reply

I fix it by this:


Edit Scheme -> Info -> Executable -> Ask on launch

Thank god!!



http://upload-images.jianshu.io/upload_images/663014-d5d182e310052664.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240

Replies

I'm having this same problem after updating my iPhone 6 to iOS 11.1 and Xcode to 9.1 Beta. I've tried toggling the "Automatically manage signing" checkbox in Xcode. Other people have reported success from this but it hasn't fixed my issue. The app will run on the iPhone after being updated by Xcode, but it will not run attached to Xcode.

I'm also seeing this in XCode 9 when running my scheme in Release with manual signing. My app previously ran on the provisioned device with no problem. XCode also confirms that the certificate and provisioning profiles are up to date, and my device is in the provisioned device list. But I still get this error:

Could not launch "[App Name]"

[Device name] denied the launch request


I have success with switching to Automatically manage signing and then it will run in Release.


For now, I guess I'm going with Automatic code signing. But I'd like to know what the real fix is here.

I had gotten the problem to go away by fixing the app icon. It had been 1039x1039 and when I took it down to 1024x1024, the problem went away.


But it's back today! Xcode 9.1 Beta 9B37, Mac OS 10.12.6, iOS 11.1 on iPhone 6.


I worked successfully without this problem for quite a while today before it quit working. Odd.

i had same issue, also automatically manage signing was turned off, but the reason was signing certificate was ad hoc for release scheme. Changed to proper distribution signing and worked just fine

I fix it by this:


Edit Scheme -> Info -> Executable -> Ask on launch

Thank god!!



http://upload-images.jianshu.io/upload_images/663014-d5d182e310052664.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240

Same error here, with Xcode 9.1 on a brand-new iPhone X, using manual Developer profiles. Haven't found a workaround yet. Can someone at Apple please look into this bug?! It's wasting literally hours.

Sad to say I'm still struggling with this also. I can't get the app to work on Simulator or on my iPhone 6. Well, it loads and works on both if the app is started manually, but I'm not able to attach the debugger in either case.


Having more than one Xcode version installed can be a problem, but I've trashed (and emptied) all except Xcode 9.1.


This is really frustrating!

Same problem here. Normally I have this bug once or twice a day and restarting my MacBook and my iPhone solved it. But today I can run like once every 20 tries or so... It's really a waste of hours and hours of trying to get the app to run. For me device AND simulator don't work!


PLEASE Apple... look into this issue and try to get the developer tools working again!!! Currently is such a pain! Clean building my swift project takes like 20 min and then I can't even install it... Thats really annoying!

Wow! This worked for me also. How in the world did you ever find this?


I can now Run on my iPhone and get debugging info on the console. Woohoo!

See the fix reported by haozes. Worked for me. It's a workaround rather than a true fix, but it's very easy.

This is not working for me. When I try it, after building/installing the app it immediately says "Finished running [app]" and the app never actually runs. :/

I saw this on Xcode Server more and more often on Xcode 9, like I tried 60 integrations, but only works for 2 times, anyone from apple can take a serious look at this ssue?

Same here, this is so annoying

Worked on my side, but it's really quirky to manuallay select the appropriate project each launch.

It works, but I don't get breakpoints when I do this.