dio icon indicating copy to clipboard operation
dio copied to clipboard

WIFI switch, No address associated with hostname

Open rj9676564 opened this issue 2 years ago • 1 comments

New Issue Checklist

  • [ YES ] I have searched for a similar issue in the project and found none

Issue Info

Info Value
Platform Name flutter / android
Platform Version 2.10.4 / 11.0
Dio Version 4.0.6 / 1.0.17
Android Studio / Xcode Version Android Studio 3.3.2
Repro rate all the time (100%)
Repro with our demo prj Dio _dio = new Dio(); _dio.fetch(RequestOptions(path: "http://baidu.com/"));

Issue Description and Steps

WIFI A: the network is normal WIFI B: LAN only If I switch from A to B, then switch from B back to A. request will receive an error.

Unhandled Exception: DioError [DioErrorType.other]: SocketException: Failed host lookup: 'baidu.com' (OS Error: No address associated with hostname, errno = 7)

Browser The network is normal, kill the process and restart the App The network is normal

rj9676564 avatar Apr 14 '22 08:04 rj9676564

Same happening with me .... I am running app in debug mode and it is giving me error

AliYar-Khan avatar Apr 30 '22 16:04 AliYar-Khan

I'm encountering the same issue on iOS

cirediew avatar Oct 07 '22 09:10 cirediew