flutter_downloader
flutter_downloader copied to clipboard
download http source err with cast to https failure in Android
ERROR MSG : W/System.err: java.lang.ClassCastException: com.android.okhttp.internal.huc.HttpURLConnectionImpl cannot be cast to javax.net.ssl.HttpsURLConnection W/System.err: at vn.hunghd.flutterdownloader.DownloadWorker.downloadFile(DownloadWorker.java:317) W/System.err: at vn.hunghd.flutterdownloader.DownloadWorker.doWork(DownloadWorker.java:235)
see the source code fo DownloadWorker,found that " ignoreSsl = getInputData().getBoolean(ARG_IGNORESSL, false);" ignoreSsl is always false
Just faced this bug myself, any fix @WoodJim?
FlutterDownloader.initialize(debug: true, ignoreSsl: true);
seems to fix the issue but it is not recommended for production application.
see the source code fo DownloadWorker,found that " ignoreSsl = getInputData().getBoolean(ARG_IGNORESSL, false);" ignoreSsl is always false
It falls back to false
. It is not always false
. I'm currently very busy but will try to take a look at it in a few weeks.
I still have this issue too. Any updates? I'm using flutter_downloader: ^1.7.4
on flutter 2.10.5
.
Is there a solution for this?
Seems like a fix should be fairly simple, if anyone's willing to do it I'll be happy to merge and release a new version.