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

Add OpenJDK as a dependency again #315

Closed
deeplow opened this issue Jan 24, 2023 · 0 comments · Fixed by #328
Closed

Add OpenJDK as a dependency again #315

deeplow opened this issue Jan 24, 2023 · 0 comments · Fixed by #328
Assignees
Milestone

Comments

@deeplow
Copy link
Contributor

deeplow commented Jan 24, 2023

The removal of openjdk in #305 introduced some unintended side-effects of removing openjdk8 in excell files:

before after
xlsxbefore xlsxafter

We missed these because we didn't manually inspect all the output files and also because the conversion process dones't fail as soon as it gets an unexpected JSON from container:

Converting document to safe PDF
[DEBUG] Marking doc GQN_Qw as 'converting'
[INFO ] > /usr/bin/podman run --network none -u dangerzone --security-opt no-new-privileges --userns keep-id --cap-drop all --rm -v /home/user/dangerzone/tests/test_docs/sample.xlsx:/tmp/input_file -v /home/user/.config/dangerzone/tmp/tmpphanvmpz/pixels:/dangerzone dangerzone.rocks/dangerzone /usr/bin/python3 /usr/local/bin/dangerzone.py document-to-pixels
[INFO ] [doc GQN_Qw] 0% Converting to PDF using LibreOffice
[ERROR] Invalid JSON returned from container:

	 javaldx: Could not find a Java Runtime Environment!

[ERROR] Invalid JSON returned from container:

	 Warning: failed to read path from javaldx

[ERROR] Invalid JSON returned from container:

	 convert /tmp/input_file -> /tmp/input_file.pdf using filter : calc_pdf_Export

[INFO ] [doc GQN_Qw] 3% Calculating number of pages
[INFO ] [doc GQN_Qw] 10% Converting page 1/6 to pixels
[INFO ] [doc GQN_Qw] 18% Converting page 2/6 to pixels
[INFO ] [doc GQN_Qw] 25% Converting page 3/6 to pixels
[INFO ] [doc GQN_Qw] 33% Converting page 4/6 to pixels
[INFO ] [doc GQN_Qw] 40% Converting page 5/6 to pixels
[INFO ] [doc GQN_Qw] 48% Converting page 6/6 to pixels

It needs to be reverted. And out tests should at least include some sort of diff so things like these get flagged.

@deeplow deeplow added this to the 0.4.1 milestone Jan 24, 2023
apyrgio added a commit that referenced this issue Jan 30, 2023
Commit d7be28e assumed that OpenJDK was
required for the PDFtk package, which is no longer installed in the
Dangerzone image, and thus was removed.

Turns out that while LibreOffice does not depend on OpenJDK, it may
produce corrupted PDFs if installed without it, and will not abort the
operation.

Reinstate OpenJDK to fix the issue of corrupted PDFs.

Fixes #315
apyrgio added a commit that referenced this issue Feb 7, 2023
Commit d7be28e assumed that OpenJDK was
required for the PDFtk package, which is no longer installed in the
Dangerzone image, and thus was removed.

Turns out that while LibreOffice does not depend on OpenJDK, it may
produce corrupted PDFs if installed without it, and will not abort the
operation.

Reinstate OpenJDK to fix the issue of corrupted PDFs.

Fixes #315
apyrgio added a commit that referenced this issue Feb 7, 2023
Commit d7be28e assumed that OpenJDK was
required for the PDFtk package, which is no longer installed in the
Dangerzone image, and thus was removed.

Turns out that while LibreOffice does not depend on OpenJDK, it may
produce corrupted PDFs if installed without it, and will not abort the
operation.

Reinstate OpenJDK to fix the issue of corrupted PDFs.

Fixes #315
@apyrgio apyrgio closed this as completed in 24975fa Feb 7, 2023
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 a pull request may close this issue.

2 participants