-
-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better opening of split zim archive. #879
Comments
@mgautierfr Yes it is broken, I have tested this scenario. When there is both |
@mgautierfr This seems mandatory to fix kiwix/kiwix-android#3605. We should create mulestone 9.2.1, as we seem to have a regression around chunk mgmt. |
The "api" to open split file is a bit buggy:
However,
If directly given path
foo.zimaa
, it succeed to open the file and so don't instanciate a MultiPart file reader (and so onlyfoo.zimaa
is read and reading of the full archive is broken).If
foo.zim
andfoo.zim[a-z][a-z]
is present, you cannot read split file (either you pass.zim
path and you open not split file, or you passfoo.zimaa
is it is broken).We should allow to pass
*.zimaa
as valid path.On top of that, we may also check that the file we have opened has a size corresponding to what is declared in the archive header. It could be used to detect this use case but also detect when the zim file is currently downloaded and so not complete.
The text was updated successfully, but these errors were encountered: