Commit b020a25d authored by Nikita Titov's avatar Nikita Titov Committed by Guolin Ke
Browse files

[ci] compatibility hotfix for notebook execution (#2048)

* ci fix

* ci fix for Appveyor

* actually firx Appveyor
parent 74ce2cfe
...@@ -53,5 +53,5 @@ test_script: ...@@ -53,5 +53,5 @@ test_script:
if (!$?) { $host.SetShouldExit(-1) } if (!$?) { $host.SetShouldExit(-1) }
} # run all examples } # run all examples
- cd %APPVEYOR_BUILD_FOLDER%\examples\python-guide\notebooks - cd %APPVEYOR_BUILD_FOLDER%\examples\python-guide\notebooks
- conda install -q -y -n test-env ipywidgets notebook - conda install -q -y -n test-env ipywidgets notebook "tornado=5.1.1"
- jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb # run all notebooks - jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb # run all notebooks
...@@ -139,6 +139,6 @@ matplotlib.use\(\"Agg\"\)\ ...@@ -139,6 +139,6 @@ matplotlib.use\(\"Agg\"\)\
sed -i'.bak' 's/graph.render(view=True)/graph.render(view=False)/' plot_example.py sed -i'.bak' 's/graph.render(view=True)/graph.render(view=False)/' plot_example.py
for f in *.py; do python $f || exit -1; done # run all examples for f in *.py; do python $f || exit -1; done # run all examples
cd $BUILD_DIRECTORY/examples/python-guide/notebooks cd $BUILD_DIRECTORY/examples/python-guide/notebooks
conda install -q -y -n $CONDA_ENV ipywidgets notebook conda install -q -y -n $CONDA_ENV ipywidgets notebook "tornado=5.1.1"
jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb || exit -1 # run all notebooks jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb || exit -1 # run all notebooks
fi fi
...@@ -38,6 +38,6 @@ if ($env:TASK -eq "regular") { ...@@ -38,6 +38,6 @@ if ($env:TASK -eq "regular") {
python $file ; Check-Output $? python $file ; Check-Output $?
} # run all examples } # run all examples
cd $env:BUILD_SOURCESDIRECTORY/examples/python-guide/notebooks cd $env:BUILD_SOURCESDIRECTORY/examples/python-guide/notebooks
conda install -q -y -n $env:CONDA_ENV ipywidgets notebook conda install -q -y -n $env:CONDA_ENV ipywidgets notebook "tornado=5.1.1"
jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb ; Check-Output $? # run all notebooks jupyter nbconvert --ExecutePreprocessor.timeout=180 --to notebook --execute --inplace *.ipynb ; Check-Output $? # run all notebooks
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment