Skip to content
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

fix: #929 raises on JPEG with image/jpg MIME-type #996

Merged
merged 1 commit into from
Aug 3, 2024

Conversation

scanny
Copy link
Owner

@scanny scanny commented Aug 3, 2024

Summary
At least one client, perhaps Adobe PDF Converter, produces a PPTX with JPEG images mapped to the non-existent image/jpg MIME-type rather than the correct image/jpeg.

Accept image/jpg as an alias for image/jpeg, which is consistent with the behavior of PowerPoint which loads these files without complaint.

Fixes: #929

At least one client, perhaps Adobe PDF Converter, produces a PPTX with
JPEG images mapped to the non-existent `image/jpg` MIME-type rather than
the correct `image/jpeg`.

Accept `image/jpg` as an alias for `image/jpeg`, which is consistent
with the behavior of PowerPoint which loads these files without
complaint.
@scanny scanny force-pushed the scanny/fix-image-jpg-mime branch from 3a54dc0 to cbdbc02 Compare August 3, 2024 05:37
@scanny scanny merged commit af6a8f7 into master Aug 3, 2024
4 checks passed
@scanny scanny deleted the scanny/fix-image-jpg-mime branch August 3, 2024 05:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error when extract 'jpeg' image from pptx, "AttributeError: 'Part' object has no attribute 'image'"
1 participant