Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It will take slightly more effort, but while we are at it, why not fix this issue for all illustrations of the NxN@1 kind?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well.. it is two different issues :)
Supporting NxN@1 is not just parse the "Illustration_NxN@1" string. This string is already fixed and is added by https://github.com/openzim/zim-tools/blob/main/src/zimwriterfs/zimwriterfs.cpp#L100-L103
We will have to extend the zimwriterfs options to allow user to pass other illustration other than 48x48 first (and if we do this, probably not pass through the
Metadata
class (or extend it to store the size as plain value)).I not really sure we should do this in this PR which "simply" set the correct mimetype for illustration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This hack creates a situation where the same bug is likely to be reintroduced for illustrations with dimensions different from 48x48 when
zimwriterfs
is enhanced to support them. One way to track it is to add an action item (with a checkbox) to the corresponding ticket (or create such a ticket if one doesn't yet exist).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's no such ticket ATM and given:
I'd say it's safe to merge as-is.