JunoLab / Weave.jl

Scientific reports/literate programming for Julia
http://weavejl.mpastell.com
MIT License
824 stars 95 forks source link

Doesn't find jupyter nbconvert #253

Open dpsanders opened 4 years ago

dpsanders commented 4 years ago
julia> notebook("01. Introduction to Julia.jmd")
[ Info: Running nbconvert
ERROR: IOError: could not spawn `jupyter nbconvert --ExecutePreprocessor.timeout=-1 --to notebook --execute '/Users/dpsanders/Dropbox/teaching/6.S083_private/lectures/01. Introduction to Julia.ipynb' --output '/Users/dpsanders/Dropbox/teaching/6.S083_private/lectures/01. Introduction to Julia.ipynb'`:

This works from the command line once I added a bash alias for jupyter, but doesn't work from within Weave.

pfitzseb commented 4 years ago

That's just a consequence of run etc not starting bash to run your code. Note that you can give the path to Jupyter as a kwarg: https://github.com/JunoLab/Weave.jl/blob/9f664ba5a6d57d8bb9e1c3dd3106ad6d311e86a6/src/Weave.jl#L174

dpsanders commented 4 years ago

It seems like this should be solved by using IJulia to work out where the jupyter executable is.