-
-
Notifications
You must be signed in to change notification settings - Fork 473
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
Kiwix cannot import ZIM files from the filesystem #4216
Comments
@MohitMaliFtechiz At least the error should contain the full ZIM path IMHO. |
@vincent-sparks Can you please tell me from where you are trying to open the ZIM file(In which folder and in which storage internal or SD card)? Ahh! you are using the Pixel 8 which does not have the SD card slot, are you using any OTG or external hard drive?
If it shows you |
@vincent-sparks Thanks for reporting the issue, can you please try this APK https://drive.google.com/file/d/1x4aIJ7BlYBAfzEH_KtxhWxmiSg83vJYm/view?usp=sharing and let us know that this version of application able to open the ZIM files from your USB or external hard drive? If there is any problem in opening the ZIM file so after trying to open the ZIM file do the following:
|
After testing the issue further, I have determined that the issue is not opening files from the internal storage, but from an app that appears in the file selector (don't know what the internal Android name for these is -- apps that present their own virtual filesystems in the file picker). My bad! Kiwix can open .zim files from my internal storage and from external USB media, regardless of their file path (as long as it is a child of /storage/emulated/0 and not /data), but if I try to open a file from e.g. Termux's internal storage, Kiwix complains it cannot find it. Behavior in all three of these cases (internal storage, external storage, Termux) is identical across this debug build and the public build on GitHub I was using before. When I tried to send a diagnostic report, Kiwix popped up a toast asking me to "Please install an email client". I have an email client installed and opening mailto: links in other apps works fine. |
@vincent-sparks Thanks for your feedback. Good to hear that it is opening the ZIM file from your USB stick.
Ohh!! So you are using the termux storage, okay I am testing this with Termux storage and get back to you ASAP.
Can you please tell me which email client/app do you have in your system? |
@vincent-sparks I have made my research on this, and here are my points: Termux uses the internal app-specific directory for storing the inside the We can access the files from the termux directory via Currently, we can't open the ZIM files via uri since we need the proper file path to open the ZIM file, and for this, we are receiving the file path from the selected file's URI but due to it being internal to the Termux app directory android does not allow to getting the path, means we can only work with the provided URI by SAF. Currently, we can't open the file from URI, and we have a ticket for this to open the ZIM files via fd openzim/libzim#852. After implementing this, this issue will be fixed. So at the moment, my suggestion is to put the ZIM files in device storage instead of termux storage. |
Describe the bug
In the Kiwix app's Library tab, if I tap the + button in the bottom right corner, a file browser opens, and I can select a ZIM file. If I choose a ZIM file, the app responds with a toast message saying "Error: The selected ZIM file could not be found." and does not do anything else.
If I manually open my phone's files app and move the ZIM file to the directory
Android/media.org.kiwixmobile.standalone/Kiwix
in the phone's storage root (i.e./storage/emulated/0
), then switch back to the Kiwix app and swipe down to reload the library, my new ZIM file appears as expected. I had to figure this out on my own and it is not at all intuitive.Expected behavior
When browsing for a file to add to the library, the app should either move, copy, or symlink the ZIM file into the directory where it will look for it.
Steps to reproduce the behavior:
Detailed above
Screenshots
Environment
Logs
Not sure how to retrieve logs but will be happy to provide them if this problem is not reproducible on other devices.
The text was updated successfully, but these errors were encountered: