Comments (16)
I've opened ucbds-infra/ottr#21 to continue exporting the submission zip if a PDF can't be generated, which should be the only change required on otter's end for this issue. It will be included in v1.5.0 of ottr, which will come out once I've fixed #767 as well.
from otter-grader.
Looks like it's not just a PDF issue, I get part of the error on Berkeley R Datahub when setting pdf = FALSE
too:
from otter-grader.
And actually, I even get an error without the force_save = TRUE
flag.
from otter-grader.
Upon further investigation, it's possible at least some of this might be tied to generic Berkeley datahub issues. https://ds-modules.slack.com/archives/C3ESHBX2N/p1705901646319269
from otter-grader.
Looks like it's not just a PDF issue, I get part of the error on Berkeley R Datahub when setting
pdf = FALSE
too:
The warning you're seeing is a separate issue -- I'm not sure why force save isn't working. But from the line below the warning, you can see that the zip file was generated, so the bug in this issue is only occurring when pdf = TRUE
.
from otter-grader.
Thanks. With the Datahub issues resolved, looks like the issue persists with force save set to TRUE but the function works without either the force save or PDF flags.
from otter-grader.
Sorry, I'm confused now. Can you send a screenshot of running with both pdf and force_save set to true now that the hub issues are resolved?
from otter-grader.
Summary:
ottr::export("Week2_Activity1.ipynb")
worksottr::export("Week2_Activity1.ipynb", force_save = TRUE)
error:
from otter-grader.
What you're seeing in ottr::export("Week2_Activity1.ipynb", force_save = TRUE)
isn't an error but a warning; the zip is still being generated. Not sure why force save isn't working but I'll open a separate issue for that.
For ottr::export("Week2_Activity1.ipynb", pdf = TRUE)
, can you open a terminal on the hub, cd
into the directory with the notebook, and run jupyter nbconvert --to=pdf Week2_Activity1.ipynb
and send the output?
from otter-grader.
For ottr::export("Week2_Activity1.ipynb", pdf = TRUE), can you open a terminal on the hub, cd into the directory with the notebook, and run jupyter nbconvert --to=pdf Week2_Activity1.ipynb and send the output?
@dbroockman, any update on this?
from otter-grader.
Traceback (most recent call last):
File "/srv/conda/bin/jupyter-nbconvert", line 6, in <module>
from nbconvert.nbconvertapp import main
File "/srv/conda/lib/python3.9/site-packages/nbconvert/nbconvertapp.py", line 193, in <module>
class NbConvertApp(JupyterApp):
File "/srv/conda/lib/python3.9/site-packages/nbconvert/nbconvertapp.py", line 252, in NbConvertApp
Options include {get_export_names()}.
File "/srv/conda/lib/python3.9/site-packages/nbconvert/exporters/base.py", line 145, in get_export_names
e = get_exporter(exporter_name)(config=config)
File "/srv/conda/lib/python3.9/site-packages/nbconvert/exporters/base.py", line 106, in get_exporter
exporter = items[0].load()
File "/srv/conda/lib/python3.9/site-packages/importlib_metadata/__init__.py", line 184, in load
module = import_module(match.group('module'))
File "/srv/conda/lib/python3.9/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "/srv/conda/lib/python3.9/site-packages/jupyter_contrib_nbextensions/__init__.py", line 5, in <module>
import jupyter_nbextensions_configurator
File "/srv/conda/lib/python3.9/site-packages/jupyter_nbextensions_configurator/__init__.py", line 18, in <module>
from notebook.base.handlers import APIHandler, IPythonHandler
ModuleNotFoundError: No module named 'notebook.base'
from otter-grader.
Looks like the hub has some incompatible package versions; I'm guessing it's an outdated version of jupyter_nbextensions_configurator
. I'd open an issue on the datahub repo that this is preventing nbconvert from being able to export notebooks as PDFs.
From this it looks like notebook v7 (which is what the hub is using) isn't compatible with notebook extensions? I'm not 100% sure.
from otter-grader.
Thank you, bug opened here: datahub-project/datahub#9732
from otter-grader.
I think that's the wrong repo. Berkeley datahub (afaik) is run from https://github.com/berkeley-dsep-infra/datahub
from otter-grader.
Thanks for the flag.
from otter-grader.
Looks like the hub has some incompatible package versions; I'm guessing it's an outdated version of
jupyter_nbextensions_configurator
. I'd open an issue on the datahub repo that this is preventing nbconvert from being able to export notebooks as PDFs.From this it looks like notebook v7 (which is what the hub is using) isn't compatible with notebook extensions? I'm not 100% sure.
yep, this is 100% the case: notebook v7 isn't compatible with notebook v6 extensions.
from otter-grader.
Related Issues (20)
- Refactor otter grade image builds so that assignment data is not included in the grading image HOT 1
- Otter-grader problems with juno app on ios HOT 4
- Cannot run grade HOT 4
- Incorrerct Grade HOT 11
- Plugins and submission_metadata HOT 4
- Otter Grade and Notebook Timeout
- Otter Grade: Write out Individual Results as well as final_grades.csv HOT 2
- Add support for Quarto assignments in R HOT 2
- Problem with variable name in test HOT 1
- Add option to get results pickle file to otter run
- R image build requires mamba gcc_linux-64 and gxx_linux-64 HOT 5
- module pkg_resources missing when you install otter-grader in a venv environment for Python 3.12+ HOT 1
- Getting two errors running otter assign HOT 1
- Otter Grade: Progress Queue HOT 2
- Otter Grade: AttributeError: 'GradingResults' object has no attribute '_catastrophic_error' HOT 5
- Make test functions get access to global variables HOT 4
- Can student manipulate the student version of the file to pass public test on student notebook? HOT 5
- Otter assign doctest generation does not handle with statements correctly
- Widget with plotly figure stalls otter assign HOT 1
- Update otter version info to include more packages
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from otter-grader.