NoHttp icon indicating copy to clipboard operation
NoHttp copied to clipboard

target 29 下载报权限异常

Open fonuhuolian opened this issue 4 years ago • 1 comments

E/ContentValues: onDownloadError: SD card isn't available, please check SD card and permission: WRITE_EXTERNAL_STORAGE. You must pay attention to Android6.0 RunTime Permissions: https://github.com/yanzhenjie/AndPermission. Failed to create file: /storage/emulated/0/oa.apk.nohttp

target 29 时 走这个回调 /** * An error occurred while downloading. * * @param what which is used to mark the download tasks. * @param exception error types. Error types include the following: *

{@link NetworkError} The network is not available, please check * the network.

*

{@link ServerError} When the response code is more than 400, you * need to look at the response code specific how much is the judgement is something wrong.

*

{@link StorageReadWriteError} An error occurred when read/write * memory CARDS, please check the memory card.

*

{@link StorageSpaceNotEnoughError} There is insufficient space on * the memory card, please check the memory card.

*

{@link TimeoutError} Timeout connecting to the server or read the * file.

*

{@link UnKnownHostError} Is not found in the network of the * target server.

*

{@link URLError} Download url is wrong.

*/ void onDownloadError(int what, Exception exception);

已经动态存储权限获取了 把target改成28就可以了

fonuhuolian avatar Jul 31 '20 03:07 fonuhuolian

API30,WRITE_EXTERNAL_STORAGE 权限有还报错,咋整啊 @yanzhenjie

kcjian avatar Aug 09 '21 07:08 kcjian