INRIA / INRIA/scikit-learn-mooc

jupyter-book / jupyter-cache minor build annoyances

Open
#329 0 comments 0 reactions 0 assignees View on GitHub
infrastructure
Dominant language
Jupyter Notebook
Stars
1.4k
Forks
600
Avg merge
6d 20h
Merged PRs (30d)
2

Description

We grep the log for some text because the jupyter-book exit code is always zero: https://github.com/INRIA/scikit-learn-mooc/blob/86e5df2479defc27a388c1fe85322571f3173f89/build_tools/circle/build_jupyter_book.sh#L17-L18

At some point maybe it would be worth following up with jupyter-book / jupyter-cache to ask:
- is there a way to make the jupyter-book exit code non-zero when a notebook fails (maybe there is already needs to double-check)
- is there a way to output a nice error with the notebook failure logs
- the fact that jupyter-cache does not show the log of the failures on the second run is annoying. In some sense the error is cached (the notebook has not changed) so it kind of makes sense but still ...
First run (note the second warning that points to the useful bit of information i.e. where can I look at the real error):
```
WARNING: Execution Failed: /home/lesteve/dev/scikit-learn-mooc/jupyter-book/python_scripts/01_tabular_data_exploration.py
WARNING: Couldn't find cache key for notebook file python_scripts/01_tabular_data_exploration.py. Outputs will not be inserted.
Last execution failed with traceback saved in /home/lesteve/dev/scikit-learn-mooc/jupyter-book/_build/html/reports/01_tabular_data_exploration.log
```

Second run (the second useful warning has disappeared it only tells you this notebook has failed but not where to look to find the actual error):
```
WARNING: Execution Failed: /home/lesteve/dev/scikit-learn-mooc/jupyter-book/python_scripts/01_tabular_data_exploration.py
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.