diff --git a/.travis.yml b/.travis.yml index 649c6e7f35..7539c7d0a1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,20 +5,29 @@ python: - 3.3 - 3.4 - 3.5 + - 3.6 +addons: + apt_packages: + - pandoc env: - - GROUP=python TRAVIS_NODE_VERSION=5.1 + - GROUP=python TRAVIS_NODE_VERSION=6.9 sudo: false before_install: - 'if [[ $GROUP == python ]] ; then bash ./scripts/travis_before_install_py.sh ; fi' + - 'if [[ $GROUP == doc ]] ; then bash ./scripts/travis_before_install_py.sh ; fi' install: - 'if [[ $GROUP == python ]] ; then bash ./scripts/travis_install_py.sh ; fi' + - 'if [[ $GROUP == doc ]] ; then bash ./scripts/travis_install_py.sh ; fi' - 'if [[ $GROUP == js ]] ; then bash ./jupyter-js-widgets/scripts/travis_install_js.sh ; fi' script: - 'if [[ $GROUP == python ]] ; then bash ./scripts/travis_script_py.sh ; fi' + - 'if [[ $GROUP == doc ]] ; then bash ./scripts/travis_script_doc.sh ; fi' - 'if [[ $GROUP == js ]] ; then bash ./jupyter-js-widgets/scripts/travis_script_js.sh ; fi' matrix: include: - - python: 3.5 + - python: 3.6 env: GROUP=js BROWSER=firefox TRAVIS_NODE_VERSION=6.9 + - python: 3.6 + env: GROUP=doc after_success: - coveralls diff --git a/docs/environment.yml b/docs/environment.yml index 9cbaf38d9f..c02fb9ebe0 100644 --- a/docs/environment.yml +++ b/docs/environment.yml @@ -3,19 +3,13 @@ channels: - conda-forge - defaults dependencies: -- sphinx=1.4.8 -- python=3.5 -- sphinx_rtd_theme -- jinja2 -- tornado -- nbformat -- ipywidgets -- notebook>=4.2 -- sphinx>=1.4.6 - ipykernel +- jupyter_client +- jupyter_sphinx +- nbsphinx +- python=3 +- sphinx - pip: - - docutils<0.13.1 - - jupyter_sphinx - - git+https://github.com/spatialaudio/nbsphinx.git#egg=nbsphinx - - python-dateutil - - recommonmark==0.4.0 + - ipywidgets>=7.0.0a2 + - jupyter-alabaster-theme + - recommonmark diff --git a/docs/requirements.txt b/docs/requirements.txt index b02d4034d3..abd65088cf 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,8 +1,8 @@ +ipykernel +ipywidgets>=7.0.0a2 +jupyter-alabaster-theme jupyter_client -sphinx>=1.4.6 -sphinx_rtd_theme==0.1.10-alpha -git+https://github.com/spatialaudio/nbsphinx.git#egg=nbsphinx jupyter_sphinx +nbsphinx>=0.2.13 recommonmark==0.4.0 -ipykernel -jupyter_sphinx +sphinx>=1.4.6 \ No newline at end of file diff --git a/docs/source/conf.py b/docs/source/conf.py index 3d7dfdfe8f..3305bc3a18 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -5,7 +5,7 @@ import os import subprocess import sys -import sphinx_rtd_theme +import jupyter_alabaster_theme import recommonmark.parser @@ -42,6 +42,7 @@ def bash(filename): 'nbsphinx', 'jupyter_sphinx.embed_widgets', 'IPython.sphinxext.ipython_console_highlighting', + 'jupyter_alabaster_theme', ] intersphinx_mapping = { @@ -75,6 +76,7 @@ def bash(filename): # -- html -------------------------- +html_theme = 'jupyter_alabaster_theme' # html_static_path = ['_static'] htmlhelp_basename = 'ipywidgetsdoc' diff --git a/docs/source/dev_docs.md b/docs/source/dev_docs.md index 118fbc5139..5542bfee5e 100644 --- a/docs/source/dev_docs.md +++ b/docs/source/dev_docs.md @@ -11,7 +11,7 @@ containing all the necessary packages (except pandoc), use: conda env create -f docs/environment.yml source activate ipywidget_docs # Linux and OS X activate ipywidget_docs # Windows -``` +``` If you want to install the necessary packages with `pip` instead, use (omitting `--user` if working in a virtual environment): diff --git a/docs/source/index.rst b/docs/source/index.rst index 4e77aaa176..ff1e1c961a 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -17,6 +17,7 @@ Contents examples/Widget Custom.ipynb examples/Widget Alignment.ipynb examples/Widget Low Level.ipynb + examples/Widget Asynchronous.ipynb embedding.md contributing.md changelog.md diff --git a/scripts/travis_before_install_py.sh b/scripts/travis_before_install_py.sh index c84caf5c9b..0226dddc7d 100644 --- a/scripts/travis_before_install_py.sh +++ b/scripts/travis_before_install_py.sh @@ -1 +1,3 @@ +set -ex + pip install --upgrade setuptools pip diff --git a/scripts/travis_install_py.sh b/scripts/travis_install_py.sh index 518266cf4d..578a0fb178 100644 --- a/scripts/travis_install_py.sh +++ b/scripts/travis_install_py.sh @@ -1 +1,3 @@ +set -ex + pip install file://$PWD#egg=ipywidgets[test] coveralls diff --git a/scripts/travis_script_doc.sh b/scripts/travis_script_doc.sh new file mode 100644 index 0000000000..84016d85c1 --- /dev/null +++ b/scripts/travis_script_doc.sh @@ -0,0 +1,9 @@ +set -ex + +pwd + +# Verify docs build +pushd docs +pip install -r requirements.txt +make html +popd diff --git a/scripts/travis_script_py.sh b/scripts/travis_script_py.sh index a99f9bf570..0b8179672b 100644 --- a/scripts/travis_script_py.sh +++ b/scripts/travis_script_py.sh @@ -1,3 +1,5 @@ +set -ex + mkdir /tmp/ipywidgets cd /tmp/ipywidgets nosetests --with-coverage --cover-package=ipywidgets ipywidgets