Skip to content
This repository

Issue where all requests timeout until the app is restarted #320

Open
Kabal opened this Issue April 26, 2012 · 5 comments

3 participants

Tom Wilson blackpawn James Munro
Tom Wilson
Kabal commented April 26, 2012

Has anyone else experienced an issue where all ASIHTTPRequests will start to time out constantly, until the app is restarted?

I'm not really doing anything fancy, really just:

__block ASIHTTPRequest request = [[[ASIHTTPRequest alloc] initWithURL:[NSURL URLWithString:@"http://domain.com/api/method.json"]] autorelease];
[request setRequestMethod:@"POST"];
[request addRequestHeader:@"User-Agent" value:[NSString stringWithFormat:@"NOW-iOS %@", [self appVersion]]];
[request addRequestHeader:@"Content-Type" value:@"application/json; charset=utf-8"];
[request addRequestHeader:@"Accept" value:@"application/json, text/javascript, */
"];
[request setShouldContinueWhenAppEntersBackground:YES];

[request setFailedBlock:^(void) {
}];
[request setCompletionBlock:^(void) {
}];
[request startAsynchronous];

If i constantly force close and restart the app, maybe 1 in15-20 times it will be stuck in a state where ALL requests time out. The only way to get out of that state seems to be to quit the app and try again.

I can mostly only reproduce this on 3G, but I may have had it happen in Wifi before.

Deleted user
ghost commented May 10, 2012

The content you are editing has changed. Reload the page and try again.

I've had this problem before. Are you using the TestFlight SDK by any chance?

Sending Request…

Attach images by dragging & dropping or selecting them. Octocat-spinner-32 Uploading your images… Unfortunately, we don't support that file type. Try again with a PNG, GIF, or JPG. Yowza, that's a big file. Try again with an image file smaller than 10MB. This browser doesn't support image attachments. We recommend updating to the latest Internet Explorer, Google Chrome, or Firefox. Something went really wrong, and we can't process that image. Try again.

Tom Wilson
Kabal commented May 10, 2012

Yes! I had already narrowed this down to the test flight SDK being the cause. Glad it's not just me...

blackpawn

ah hit by this too. :/ anyone find fix or workaround?

Tom Wilson
Kabal commented June 12, 2012

I tried replacing ASI with AFNetworking - it suffers the same fate.

I ended up just removing the TestFlight SDK. It wasn't doing that much for me anyway except for the crash reports which I have since replaced with Crashlytics.

James Munro

I was suffering with this issue - resorted to removing the TestFlight SDK too. They still haven't fixed it after several months now.

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.