I recently updated to OS X El Capitan, and along with that Xcode 7.1.1. Now whenever I try to run a project in Xcode, I get an issue in the Main.storyboard saying: [IBUIViewControllerAutolayoutGuide shouldBeArchived]: unrecognized selector sent to instance 0x7fee7a5f8390.
As a result, it's impossible for me to run anything :-(. Does anyone have an idea as to what to do about this?
Thanks
Harry
Related
I couldn't find any related topic so I am starting the new one.
I have macOS Sierra and latest xcode 8.
When I attach my iPhone to macbook and try to build even clean project in xcode I get following swift compiler errors:
Attempting to use the forward class 'UIViewController' as superclass of 'UIActivityViewController'
Attempting to use the forward class 'UIViewController' as superclass of 'UIAlertController'
And so on. Error count is 21 and is always same no matter what project I choose.
Someone have same problem? Any solution?
Thanks for any answer.
I know this is kind of a dupe, but I don't have enough reputation yet to comment on the original post and, while I don't have an answer, I do have more useful information (a concrete example). Moderators, feel free to move this to the proper location.
When compiling my code using the latest XCode 8 beta 6 (iOS 10 SDK), I get an exception "Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIDeviceRGBColor countByEnumeratingWithState:objects:count:]: unrecognized selector sent to instance 0x600000071340'"
This happens during the call:
auto viewController = [[[UIViewController alloc] initWithNibName:#"ViewController" bundle:nil] autorelease];
I have isolated the problem by whittling down my project to the bare minimum that will compile and still exhibit the problem. You can download it here:
Example project
Note that I took out lots of code, nearly all classes are gone, which results in a lot of warnings (not errors) for nonexistent classes referenced from the xib. But that doesn't matter, the code still compiles and runs just fine with the iOS 9 SDK. After compiling with the iOS 10 sdk, however, it crashes both in the simulator and on devices running iOS 9.
You can work around the problem by changing "#if 0" into "#if 1" in the file "HackForUnrecognizedSelectorInIOS10.m". This adds a category defining the missing selectors for UIColor. But obviously you can't add that to shipping code, it's just a temporary stopgap measure to continue developing.
I filed a bug report (28153870). But if anyone has any more information on how to avoid this problem without ugly hacks, any information is welcome.
Thanks
Michel Colman
When I try to compile and run my project with the same configuration (XCode 8 beta 6, iOS 10 SDK), I encountered a similar issue, except that my error message was:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIDeviceRGBColor length]: unrecognized selector sent to instance 0x600000479280'
And I noticed that this issue only occurs when the view is init by using interface files, i.e. Xib and Nib. I solved this issue by:
Open your interface file, in the right panel, navigate to the File Inspector tab.
Change the attribute highlighted to "iOS 7.0 and Later" (or whatever iOS version later)
Then compile and run your project again, this should fix your issue, though I am not sure about the reason behind this. I tried the same with your sample project and it solves the issue too.
In my case, I needed to change the project deployment target to 8.0 in the product general settings. Thanks to the hint from the accepted answer!
When running my code on one computer the app crashes with this error:
*** Assertion failure in -[UITableView layoutSublayersOfLayer:], /SourceCache/UIKit/UIKit-2935.137/UIView.m:8794
But when running it on another computer the program works just fine.
What could be the reason for that?
Apparently it was an iOS version issue. So when I tried building it on the Xcode simulator it worked. on the contrary of running it on an iPhone 4 / iOS 7..
Thank you David 'mArm' Ansermot and trojanfoe for helping me solve it.
I just updated to the latest Xcode, version 6.2 and started seeing this error when running my app.
libc++abi.dylib: terminating with uncaught exception of type std::runtime_error: sqlite3 libversion mismatch: headers report 3007013, but library reports 3008005
The error shows up running in the simulator using iOS 8.2, but works fine in iOS 8.1. My app includes libsqlite3.dylib from Apple.
Any suggestions on the cause or how to resolve?
Looks like an issue with MapboxGL and ios 8.2 as described here:
https://github.com/mapbox/mapbox-gl-native/issues/968
This looks like the version check in question:
https://github.com/mapbox/mapbox-gl-native/blob/b56b618abf0b15025b61ab96dcc873cf7af82450/platform/default/sqlite3.cpp
Good day! I have strange problem with Xcode 5.0.1. When I'm trying to run the app - it crashes with the following exception: UNCAUGHT EXCEPTION (NSInvalidArgumentException): must provide a file handle or pipe
I have also reinstalled Xcode (from the app store) and I have still obtained the same result.
I had this problem when updating from 5.0.0 to 5.0.1. The fix was that I was using 10.9 DP1. Now having 10.9, the final version and a fresh xcode install, it ran fine.
i have facing same problem but with little change resolve my issues.
Change littile syntex like as show below
-(void)SelectBg;
change to
-(void)SelectBg:(id)sender;
Thanks and happy coding