iOS 10.3 suddenly stops networking
Asked Answered
C

1

7

I update my phone to iOS 10.3 today. And I suddenly faced a networking issue. I am using AFNetworking. I also try NSURLConnection but no luck.

The error is "Network connection was lost (1005)".

It is working fine in all lower version.

The important things i noticed that some small response body API is working but large response body API is not working.

My request time out is 60.

In Postman all the small and large API is working fine.

I also check for keep-alive header in server side but no luck.

Following are my request header paramater:

Content-Type : application/json
Content-Encoding : gzip
Content-Length : 217125
Connection : close
Server : Apache/2.4.18(Ubuntu)
Vary : Accept-Encoding
Date : Tue, 28 Mar 2017 06:33:50 GMT

I tried this link ==> https://mcmap.net/q/100130/-error-domain-nsurlerrordomain-code-1005-quot-the-network-connection-was-lost-quot but no luck

One more thing I tried to load URL in safari and google chrome in my V10.3 iOS device but same error occurred ==> "Network connection was lost (1005)"

Is this issue of iOS 10.3?

Anyone who faced and solve this issue please help me.

Thanks.

Climacteric answered 28/3, 2017 at 7:18 Comment(9)
There are several questions if you search for "NSURLSession 1005" (the actual error code seems to be minus 1005, i.e. -1005 -unless I'm mistaken). Did you try any of the solutions?Tufthunter
Sorry, it is -1005 ==> Error Domain=NSURLErrorDomain Code=-1005 "The network connection was lost. I tried every possible solution.Climacteric
Have you found a solution to this @Parimal? I'm getting exactly the same issue... Nothing has changed either in the app or on the server - something has definitely changed in 10.3 which has caused this, as the app is still working perfectly fine on pre-10.3 devices. :(Freud
...actually, it looks like I'm still using v2 of AFNetworking, along with the associated deprecated calls to NSURLConnection. I expect this might be a factor, so I'm currently in the process of upgrading to v3. I expect this will resolve the issues, but I'll report back whether this was successful or not!Freud
Hey jt_uk, Yes I solved my problem. I am using php server and used library for caching. I just remove caching and echo entire output. And its get working.Climacteric
I am having the same issue using NSURLSession. My error started this week, and the code is the same for long before that.Nanoid
Please provide some more details. Which library are you using for networking? Do you have any server side caching? How you echo the output?Climacteric
@Climacteric did you guyz find any solution?Miamiami
@Freud can you elaborate on your solution?Miamiami
M
0

@Parimal solved their own issue in comments

I am using a php server and a library for caching. Removing the caching and echoing the entire output resolved the issue. It is now working.

Mcfall answered 28/3, 2017 at 7:18 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.