kiwix / kiwix-tools

Command line Kiwix tools: kiwix-serve, kiwix-manage, ...
https://download.kiwix.org/release/kiwix-tools/
GNU General Public License v3.0
459 stars 87 forks source link

kiwix-manage can not really deal properly with missing ZIM files #235

Closed kelson42 closed 5 years ago

kelson42 commented 5 years ago

If I remove the zim before removing it from library.xml I get an error, which shouldn't really be an error IMO. I think we discussed this before, but I raise it again in case it can be fixed.

kiwix-manage /library/zims/library.xml.tmp remove 006cbd1b-16d8-b00d-a584-c1ae110a94ed
Invalid /library/zims/content/granbluefantasy_en_all_all_nopic_2018-10.zim : error 2 opening file "/library/zims/content/granbluefantasy_en_all_all_nopic_2018-10.zim

Reported first in https://github.com/kiwix/kiwix-tools/issues/228#issuecomment-437101572

mgautierfr commented 5 years ago

It seems that it is just a message displayed. The book is actually removed from the library.

Can you confirm it is a bug on your side ?

kelson42 commented 5 years ago

@tim-moody Please confirm @mgautierfr This message should be a proper warning or even totally remove (my personal preference), but this is not an "error".

tim-moody commented 5 years ago

I confirm that the zim is actually removed and that the error message is just a nuisance. I thought perhaps kiwix-manage returned a non-zero exit, but I am not sure about that. As long as a python subprocess does not error out on this warning I am OK with it. My preference is also to remove it.