Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialTaylor Shaw
472 PointsSIGBRT error
I am about 6 minutes into the video and I have watched it several times and copied it space by space and I still get a SIGBRT error. I get [<LoginViewController 0x9aefc50> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key Login.' every time I try to run it. How do I properly define the key?
7 Answers
Bradley Maskell
8,858 PointsNevermind. If you have this problem go to > main.storyboard > InboxViewController > outlets and look for the one outlet connection that has an exclamation point. Delete it and your app should work fine.
Mike Baxter
4,442 PointsDo you happen to have any instance variables named "Login"? If so, then you can't name your IBAction "Login". Try renaming your action (and of course, redo the connection in Interface Builder) and see if that works.
Taylor Shaw
472 PointsNot that I know of I used all of the code for Login and did not see anything that would cause the error. I changed the named and reconnected the view controller several times trying the names signin, start and jim. I am still getting the "[ setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key Login."
Taylor Shaw
472 PointsIt also says NSexception (lldb) in the debugger pane if that helps?
Mike Baxter
4,442 PointsMaybe try the advice from Stackoverflow for a similar error message:
"Check your connections in Interface Builder. You're probably referring to a non existent IBOutlet or IBAction." - from Gabriele Petronella
Bradley Maskell
8,858 PointsI'm getting the same warning. I'm not referring to a non existent IBOutlet or IBAction. I downloaded the teachers project files and ran them in Xcode and they match perfectly and even the teachers code doesn't work. Please help.
arshin
17,770 PointsThe example files function well provided you have the latest frameworks installed.
Hint: Delete Parse.framework and add the new version from parse.com
Taylor Shaw
472 PointsTaylor Shaw
472 Points(IBAction)Login:(id)sender { NSString *username = [self.usernameField.text stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]];
NSString *password = [self.passwordField.text stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]];
if ([username length] ==0 || [password length] ==0) { UIAlertView *alertview = [[UIAlertView alloc] initWithTitle:@"slow down!" message:@"Make sure you enter a username and password!" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil]; [alertview show]; } else { [PFUser logInWithUsernameInBackground:username password:password block:^(PFUser *user, NSError *error) {
}