openzim / python-scraperlib

Collection of Python code to re-use across Python-based scrapers
GNU General Public License v3.0
17 stars 16 forks source link

Add utility function to confirm ZIM can be created at given location / name #163

Closed benoit74 closed 2 weeks ago

benoit74 commented 1 month ago

In warc2zim, we have a tooling which confirms that:

This is run at the beginning of the scraper, to avoid loosing time scraping stuff and then failing many hours later.

https://github.com/openzim/warc2zim/blob/32d1a20e5df425ed737f07d91155978fe0a92bed/src/warc2zim/converter.py#L127-L162

Sharing this logic in zimscraperlib would be great since all scrapers should do these checks indeed.