Skip to content
This repository

RKTwitter Example failing #1077

Closed
devangmundhra opened this Issue · 4 comments

2 participants

Devang Mundhra Blake Watters
Devang Mundhra

Hi,

I am just started out with RestKit and was trying to run the examples but unfortunately none of the examples are working.
I am on the latest development branch as of today (last commit a424908)

The first problem was in RKTwitterAppDelegate where XCode was complaining that there was no Root View Controller.
To fix that, I modified:
[window addSubview:controller.view];
to
window.rootViewController = controller;

The other problem after that is at RKHTTPRequestOperation.m:44
https://github.com/RestKit/RestKit/blob/development/Code/Network/RKHTTPRequestOperation.m#L44

This happens during app startup and crashes with the error-

2012-12-14 02:50:53.555 RKTwitter[86301:3f03] -[__NSCFDictionary objectForKeyedSubscript:]: unrecognized selector sent to instance 0x8c3f9a0
2012-12-14 02:50:53.555 RKTwitter[86301:3f03] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSCFDictionary objectForKeyedSubscript:]: unrecognized selector sent to instance 0x8c3f9a0'

Is there any setup to be done to run the examples. I have just cloned the development branch, opened the RKTwitter example XCode project and ran it.

Thanks!

Blake Watters

The examples are currently running fine under iOS 6.0. I have removed the use of keyed subscripts in the RKHTTPRequestOperation.m file -- I thought I had already cleared all of those up, but alas I missed that one.

I am looking into the start up issues on RKTwitter under 5.x now. I moved the deployment target for the Core Data example to 6.0 because I modernized its views to use autolayout, so it no longer runs under 5.0.

Will push a fix for the RKTwitter under 5.0 today and close this issue out.

Blake Watters

Setting an explicit Deployment Target on the RKTwitter project prevents the crashes on startup, but I am still getting a totally blank UI.

Blake Watters

Alrighty, apologies on this. All fixed up and verified under iOS 5.x. The RKTwitter example runs on iOS 5, the others have iOS 6 dependencies.

Devang Mundhra

Works perfectly now. Thanks!

stojanovicigi stojanovicigi referenced this issue from a commit in CenterDevice/RestKit
Blake Watters blakewatters Set deployment target to iOS 5. refs #1077 d264cf9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.