Downloading through download Manager in android sometimes does not download and throw error path appears to be invalid and it corrects itself after sometime. This is very unusual behaviour of Android Download Manager .
I am downloading to external storage through request.setDestinationInExternalPublicDir("/app/" , my_app.apk)
And when it does not download it throw this error in logcat:-
W/DownloadManager: Path appears to be invalid: /storage/emulated/0/app/my_app.apk
I think its because i am downloading in custom directory in Android but i cannot use Environment.DIRECTORY_DOWNLOADS
in this i have to download only in custom directory .
Please let me know if some one has an answer .)