-
Notifications
You must be signed in to change notification settings - Fork 89
RHOAIENG-16568: [Bug] Unable to download notebook as a PDF from JupyterLab Workbenches #1030
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
RHOAIENG-16568: [Bug] Unable to download notebook as a PDF from JupyterLab Workbenches #1030
Conversation
…erLab Workbenches
Thanks, William, for the fix! The implementation looks good to me. I ran the minimal image generated from this PR locally, and I was able to successfully generate the PDF 🥳.Aside from Jiri’s comments, I noticed a few extra blank white lines that I’d like to remove. Also, it seems the TexLive library increases the size of the minimal by approximately 700 MB. /lgtm |
@@ -8,6 +8,9 @@ if [ -f "${SCRIPT_DIR}/utils/setup-elyra.sh" ]; then | |||
source ${SCRIPT_DIR}/utils/setup-elyra.sh | |||
fi | |||
|
|||
export PATH=/usr/local/texlive/2025/bin/x86_64-linux:$PATH |
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.
Any suggestion on where to set the path? I am currently doing it in start-notebook.sh
Could be set in Dockerfile itself, but it appears we don't do it anywhere else this way.
Alternatively, leave this and let the test set its PATH anew, like in
f"bash -c 'RSTUDIO_PANDOC=/usr/lib/rstudio-server/bin/quarto/bin/tools/x86_64 Rscript {self.APP_ROOT_HOME}/script.R'", |
Hello @jiridanek I added a test and changed the path configuration to the |
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.
/lgtm
Excellent work
tested with following:
- Repo clone and exported as pdf: https://github.com/harshad16/data-science-pipeline-example/tree/master/run-pipelines-on-data-science-pipelines
- works as expected 🎉
separate question:
@jesuino , can you share for knowledge share, if version of pandoc 3.6.4 was consider for some special reason instead of the 3.7 ? so that , these reason can be consider for next upgrades.
@harshad16 thanks for testing it!
No special reason. I tested with latest pandoc and it works, so I updated the version |
@jiridanek thanks for letting me know about this config. I did add an entry for pandoc, but I don't know if I had to add some specific name, so I used |
🤞🏽 I never know this either. I normally just try this again and again until I figure out something that works. If you look what the gha runs, it should not be hard to reproduce on your own laptop, to iterate faster. (We do have open ticket to document, #1086) |
Did not work. I can check tomorrow morning and try figuring something out, so that you don't waste time on this. Imo what you'd have to do add it to the plain
edit: that ^^^ worked for me in https://github.com/jiridanek/notebooks/actions/runs/15404297288, trying to push the commit here |
Hello @jiridanek thanks again for ignoring that warning. I see that only image |
I could not reproduce this failing test locally. Could this be a flaky test? To run locally first I build the image:
Then I run the test:
|
@jesuino no, it's a flaky image build! If you check build logs, you see
And this |
thank you @jiridanek I expected the build to fail in such cases (fail fast), hence why I didn't check the logs, saw the failed test and thought it was the culprit! |
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.
Thanks for the upgrade to latest version
work as expected
Tested on:
podman run -p 8888:8888 quay.io/opendatahub/workbench-images:jupyter-datascience-ubi9-python-3.11-pr-1030
The export of PDF works as expected.
(app-root) pandoc --version
pandoc 3.7.0.2
Features: +server +lua
Scripting engine: Lua 5.4
User data directory: /opt/app-root/src/.local/share/pandoc
Copyright (C) 2006-2024 John MacFarlane. Web: https://pandoc.org
This is free software; see the source for copying conditions. There is no
/lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: harshad16 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
858b1b8
into
opendatahub-io:main
This is a fix for issue #210
Description
It install TexLive following instructions from TexLive Quick Installation guide. It uses the minimal scheme and other important dependencies are added.
The full installation increased the image size by a few GB. Additionally, the full installation adds more vulnerabilities to the published image. So starting from a minimal installation is a must. To compare images with different installation methods, check the ones I have published in my quay.io, the oldest one is the full TexLive installation
Notice also that the packages required for adding the required dependencies are not available in UBI9 base image, hence why we had to manually install this.
Finally we also disable other option that does not work.
How Has This Been Tested?
Manually tested by creating and importing some notebooks and then exporting it to PDF.
To test:
Save and Export Notebook As
.Merge criteria: