Reachability
Reachability copied to clipboard
Sometimes unreachableBlock gets called when internet is turned back on.
I am having the same issue is this http://stackoverflow.com/questions/19367351/tony-million-reachability-says-unreachable-when-connected
I tried to fix by using a delay for the code called in the unreachable block, but then cancel all delayed method calls if reachableBlock is called.
This is huge problem!
Do you get a follow up "reachable" at all?
In addition can you give me a system spec so I can try and replicate it.
Have you seen this comment: https://github.com/tonymillion/Reachability/blob/master/Reachability.m#L243
Seeing this also in simulator and multiple devices on iOS8. unreachable
block is called and isReachable is false
, yet my requests are succeeding.
In reachabilityChanged:
, the flags
parameter is 0.
To fix it you can use -reachabilityForInternetConnection
instead -reachabilityWithHostname
.
Yep, I'm seeing this too. Turn off Wifi and unreachableBlock gets called. Turn wifi back on and both reachableBlock and unreachableBlock get called. Unfortunately unreachableBlock get's called after. Normally I set a property here to indicate no network so it's a problem although I could work round it. Be nice to have a fix though....
Having the same problem in simulator 8.3
+1 to having this issue. +1 to resolving it by changing from reachabilityForInternetConnection
to reachabilityWithHostname
+1 having this issue as well and it looks like this is a bug with SCNetworkReachability to me as various libraries that use it (AFNetworking,KSReachability, this one) have this same issue