java.util.zip.ZipException: File too short to be a zip file
- Dominant language
- C++
- Stars
- 7k
- Forks
- 1.6k
- PR merge metrics
- No merged PRs in 30d
Description
出现这个异常,好像是patch包太小了?
java.util.zip.ZipException: File too short to be a zip file: 0
10-10 02:33:38.107 4009-4009/? E/PatchManager: at java.util.zip.ZipFile.readCentralDir(ZipFile.java:376)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at java.util.zip.ZipFile.(ZipFile.java:163)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at java.util.jar.JarFile.(JarFile.java:199)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at java.util.jar.JarFile.(JarFile.java:182)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at java.util.jar.JarFile.(JarFile.java:168)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.alipay.euler.andfix.patch.Patch.init(Patch.java:75)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.alipay.euler.andfix.patch.Patch.(Patch.java:67)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.alipay.euler.andfix.patch.PatchManager.addPatch(PatchManager.java:126)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.alipay.euler.andfix.patch.PatchManager.initPatchs(PatchManager.java:112)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.alipay.euler.andfix.patch.PatchManager.init(PatchManager.java:105)
10-10 02:33:38.107 4009-4009/? E/PatchManager: at com.taobao.andfixtest.MyApp.onCreate(MyApp.java:24)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at com.alipay.euler.andfix.patch.Patch.init(Patch.java:75) and follow PatchManager.addPatch and initPatchs from the reported stack trace. Inspect how the patch file reaches JarFile and verify whether the patch is empty or truncated; done means identifying the cause of the zero-length archive and confirming valid patch loading without this exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100