okdownload
okdownload copied to clipboard
Response code can't handled on internal 200 with current offset
OkDownload Version
v1.0.2-SNAPSHOT
Problem Describe
I occur some problem, I also search on issues and wiki, I even checked the source code, but it can't help, so my real problem is:...
Log
There is the whole log from LogCat when I occur the problem(I know we can use this tool to let log more readable):
I also encountered this problem.
The same problem happened, it can be reproduced easily by frequently disconnect and connect network during downloading.
The location throw this exception is at line 133 of BreakpointRemoteCheck
:
if (!isTrialSpecialPass(responseCode, instanceLength, resumable)
&& downloadStrategy.isServerCanceled(responseCode, info.getTotalOffset() != 0)) {
throw new ServerCanceledException(responseCode, info.getTotalOffset());
}
The offset of BlockInfo
is wrongly calculated, so DownloadStrategy#isServerCanceled
return true...
Remove BreakpointInfo
from BreakpointStore
can avoid this exception, like this:
OkDownload.with().breakpointStore().remove(task.getId());
But the breakpoint retransmission mechanism loses its meaning. TT
@monkey1992 Why you said the offset of BlockInfo is wrongly calculated?
Any update on this issue?
Any update on this issue?
Any update on this issue?
unsubscribe https://github.com/notifications/unsubscribe-auth/ALVMTLS6PQBMMHAYUEV436LR24N7HANCNFSM4ILSLIZA please
On Fri, 10 Jul 2020 at 15:06, Joursion [email protected] wrote:
Any update on this issue?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/lingochamp/okdownload/issues/287#issuecomment-656694857, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALVMTLS6PQBMMHAYUEV436LR24N7HANCNFSM4ILSLIZA .
com.liulishuo.okdownload.core.exception.ServerCanceledException: Response code can't handled on internal 200 with current offset 4128507 2021-12-22 17:16:02.898 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.core.download.BreakpointRemoteCheck.check(BreakpointRemoteCheck.java:133) 2021-12-22 17:16:02.900 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.core.download.DownloadCall.execute(DownloadCall.java:180) 2021-12-22 17:16:02.901 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.core.NamedRunnable.run(NamedRunnable.java:32) 2021-12-22 17:16:02.903 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.core.dispatcher.DownloadDispatcher.syncRunCall(DownloadDispatcher.java:369) 2021-12-22 17:16:02.905 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.core.dispatcher.DownloadDispatcher.execute(DownloadDispatcher.java:183) 2021-12-22 17:16:02.906 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.DownloadTask.execute(DownloadTask.java:535) 2021-12-22 17:16:02.908 20401-20401/com.uiot.smartscreen.ota W/System.err: at com.liulishuo.okdownload.DownloadContext$1.run(DownloadContext.java:124) 2021-12-22 17:16:02.910 20401-20401/com.uiot.smartscreen.ota W/System.err: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162) 2021-12-22 17:16:02.911 20401-20401/com.uiot.smartscreen.ota W/System.err: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)