lingochamp / lingochamp/FileDownloader

文件第二次下载会删除之前下载好的文件,这是为什么

Open
#1,423 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
11.1k
Forks
2.2k
PR merge metrics
No merged PRs in 30d

Description

文件第二次下载会删除之前下载好的文件,这是为什么
2023-09-17 10:17:10.812 10048-10048 MultiDownload com.mssm.demoversion D pending taskId:-270459960,fileName:null,soFarBytes:0,totalBytes:0,percent:NaN
2023-09-17 10:17:11.241 10048-10252 MultiDownload com.mssm.demoversion D blockComplete taskId:-270459960,filePath:/storage/emulated/0/MSSMDownload,fileName:20230916_fb4b4fee131a4538a2d52d08f0a0757a.jpg,speed:0,isReuse:true
2023-09-17 10:17:11.251 10048-10252 MultiDownload com.mssm.demoversion D blockComplete: mTaskCount = 1
2023-09-17 10:17:11.282 10048-10048 MultiDownload com.mssm.demoversion D pending taskId:-270459960,fileName:null,soFarBytes:0,totalBytes:0,percent:NaN
2023-09-17 10:17:11.365 10048-10255 MultiDownload com.mssm.demoversion D blockComplete taskId:-270459960,filePath:/storage/emulated/0/MSSMDownload,fileName:20230916_fb4b4fee131a4538a2d52d08f0a0757a.jpg,speed:0,isReuse:true
2023-09-17 10:17:11.381 10048-10255 MultiDownload com.mssm.demoversion D blockComplete: mTaskCount = 0
2023-09-17 10:17:11.391 10048-10255 MultiDownload com.mssm.demoversion D completed

然后第二次20230916_fb4b4fee131a4538a2d52d08f0a0757a.jpg这个文件就被删除了
这是为什么,应该怎么解决

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the second download using the MultiDownload flow and compare the logged taskId, filePath, fileName, and isReuse values across both attempts. Trace the repeated-download handling until the existing file is removed, then verify that completing the second download preserves the first file.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.