2017-12-07 - 报错 255 和 HTTP 权限问题

2017/12/7 posted in  工作总结

报错信息:failed with exit code 255

Command /Applications/Xcode.app/Contents/Developer/usr/bin/ibtool failed with exit code 255
  • clean your project

  • delete the cached data (Organizer->Projects->Derived Data tap 'Delete...'

  • insure that for this XIB the proper

  • versioning is set (select XIB, 3rd Xcode tab on right, File options:
    close the project

  • quit Xcode

  • reopen Xcode, then the product

  • try again

Push 所要做的内容:

self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
self.window.backgroundColor = [UIColor whiteColor];
UINavigationController *nav= [[UINavigationController alloc]init];
self.window.rootViewController = nav;
    
ViewController  *rootView = [[ViewController  alloc] init];
[nav addChildViewController:rootView];
    
[self.window makeKeyAndVisible];

iOS 9 HTTP 请求报错:

App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.
  • 解决方案:
1.在 Info.plist 中添加 NSAppTransportSecurity 类型 Dictionary。
2.在 NSAppTransportSecurity 下添加 NSAllowsArbitraryLoads 类型 Boolean, 值设为 YES