From 5ddcf42a107b0bcadc673afee05af1966ef9d1b5 Mon Sep 17 00:00:00 2001 From: Long Vu Date: Fri, 22 May 2020 07:40:38 -0400 Subject: [PATCH 1/2] project repo Makefile: do not execute xdg-open since it hangs in TravisCI build Backport from https://github.com/Ouranosinc/raven/pull/272/commits/a5754adf70e0437414222f6cbbed623f386e5c1d --- {{cookiecutter.project_repo_name}}/Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/{{cookiecutter.project_repo_name}}/Makefile b/{{cookiecutter.project_repo_name}}/Makefile index d55d92ece..814548d99 100644 --- a/{{cookiecutter.project_repo_name}}/Makefile +++ b/{{cookiecutter.project_repo_name}}/Makefile @@ -140,8 +140,9 @@ refresh-notebooks: docs: @echo "Generating docs with Sphinx ..." @-bash -c '$(MAKE) -C $@ clean html' - @echo "Opening browser to: file:/$(APP_ROOT)/docs/build/html/index.html" - @-bash -c 'xdg-open $(APP_ROOT)/docs/build/html/index.html' + @echo "Open your browser to: file:/$(APP_ROOT)/docs/build/html/index.html" + ## do not execute xdg-open automatically since it hangs travis and job does not complete + @echo "xdg-open $(APP_ROOT)/docs/build/html/index.html" ## Deployment targets From e02632d22f7a3311c4b449bb7088b55d94bc0c35 Mon Sep 17 00:00:00 2001 From: Long Vu Date: Fri, 22 May 2020 09:12:02 -0400 Subject: [PATCH 2/2] project repo docs conf: do not execute notebooks because we use mock imports To avoid docs build failure. Backport from: https://github.com/Ouranosinc/raven/pull/272/commits/8d1a83061e172a125c485df8d0ee2c9bd2c74701 --- {{cookiecutter.project_repo_name}}/docs/source/conf.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/{{cookiecutter.project_repo_name}}/docs/source/conf.py b/{{cookiecutter.project_repo_name}}/docs/source/conf.py index e2bab73e3..e1384f118 100755 --- a/{{cookiecutter.project_repo_name}}/docs/source/conf.py +++ b/{{cookiecutter.project_repo_name}}/docs/source/conf.py @@ -47,6 +47,9 @@ "IPython.sphinxext.ipython_console_highlighting", ] +# We are using mock imports in readthedocs, so probably safer to not run the notebooks +nbsphinx_execute = 'never' + # Add any paths that contain templates here, relative to this directory. templates_path = ["_templates"]