Unable to run the Simulator The operation couldn’t

2019-02-27 13:42发布

问题:

Im trying to run the IOS9 iphone 6 app in Xcode 7 and swift 2.0, but I can't. If I reset the content and Simulator settings, the first time works but the second one fails again, I have cleaned up the app, I have cleaned the build folder, I have tried setting the NSAllowsArbitraryLoads key to yes, Sorry, but I have a headache searching what's going on. Appreciate help

the error in the coresimulator.log is

    07/10/15 21:51:02,800 com.apple.CoreSimulator.CoreSimulatorService[410]: 
Error Domain=LaunchServicesError Code=0 "(null)" 
UserInfo={Error=PackagePatchFailed, 
ErrorDescription=Could not hardlink copy
 /Users/edu/Library/Developer/CoreSimulator/Devices/F25180D1-32CD-47E0-9823-D1626546D660/data/Containers/Bundle/Application/7E6A0B88-3B33-435F-A645-3367B6F47154/vippler.app.ios.app 
to /Users/edu/Library/Developer/CoreSimulator/Devices/F25180D1-32CD-47E0-9823-D1626546D660/data/Library/Caches/com.apple.mobile.installd.staging/temp.LDNqVX/extracted/Payload/vippler.app.ios.app 
with manifest /Users/edu/Library/Developer/CoreSimulator/Devices/F25180D1-32CD-47E0-9823-D1626546D660/data/Library/Caches/com.apple.mobile.installd.staging/temp.LDNqVX/extracted/com.apple.deltainstallcommands.com.Bitamine.vippler-app-ios}

and the screenshot of the info.plist is

回答1:

From the screenshot, it's clear that your Info.plist is missing a CFBundleVersion ("Bundle Version") key. If that key is missing, it can cause this problem.



回答2:

Based on error description Error=PackagePatchFailed, ErrorDescription=Could not hardlink copy we would say the compiler couldn't find the path of the resource such as frameworks, images. But the main problem probably is Pod. So try to delete all the cached files by following these steps

  1. command shift G
  2. paste this path /Library/Developer/Xcode/DerivedData
  3. delete relevant finders
  4. Reset Content and settings of the simulator
  5. re-compile the project

Cheers



回答3:

Changing the entire project root directory path seems to somehow work for me



回答4:

Make the Exception In Transport Security along with the "NSAllowsArbitraryLoads"