Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable Binder #2198

Merged
merged 71 commits into from
May 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
571ba5d
add binder link
MarcSkovMadsen Apr 16, 2021
bf308b9
add binder requirements
MarcSkovMadsen Apr 16, 2021
747171e
replaced deprecated pandas.util.testing
MarcSkovMadsen Apr 16, 2021
5b4de05
add more example packages
MarcSkovMadsen Apr 16, 2021
8916b14
fix deprecation warning
MarcSkovMadsen Apr 16, 2021
f1abcb2
fix images too small
MarcSkovMadsen Apr 16, 2021
e32ec8c
fix height issue
MarcSkovMadsen Apr 16, 2021
a3a689e
add postBuild for VTK dependencies
MarcSkovMadsen Apr 16, 2021
3f97435
update iris.json link
MarcSkovMadsen Apr 17, 2021
f31f88e
add apt-get install for vtk
MarcSkovMadsen Apr 17, 2021
32f49c2
add bokeh data
MarcSkovMadsen Apr 17, 2021
5813978
remove vtk apt packages
MarcSkovMadsen Apr 17, 2021
62b0a9b
fix autocomplete not shown
MarcSkovMadsen Apr 17, 2021
e6ffe87
fix missing pandas.testing references
MarcSkovMadsen Apr 17, 2021
9e0cd5a
add panel build to make sure the dist is updated
MarcSkovMadsen Apr 17, 2021
a4db462
add panel apps to server
MarcSkovMadsen Apr 17, 2021
e850ba4
serve gallery examples in nice template
MarcSkovMadsen Apr 17, 2021
6b5f36f
add vs code server proxy
MarcSkovMadsen Apr 17, 2021
bebba49
fix vs code install
MarcSkovMadsen Apr 17, 2021
99a26a0
added some more usefull VS Code extensions
MarcSkovMadsen Apr 17, 2021
004019f
update index.html template
Apr 19, 2021
fc7c826
add query args
Apr 20, 2021
c9a8900
fix href
Apr 20, 2021
e2efac3
update altair_choropleth example
MarcSkovMadsen Apr 20, 2021
2c4798d
Merge branch 'master' of https://github.com/holoviz/panel into binder
MarcSkovMadsen Apr 20, 2021
fe8e4cc
add libgl1-mesa-glx
MarcSkovMadsen Apr 20, 2021
f246c4f
remove libgl1-mesa-glx
MarcSkovMadsen Apr 20, 2021
6701a5c
add app template to gallery examples
MarcSkovMadsen Apr 20, 2021
da0f895
fix vtk
MarcSkovMadsen Apr 22, 2021
7a12f89
fix VTK
MarcSkovMadsen Apr 22, 2021
68f193f
follow pyvista cookiecutter
MarcSkovMadsen Apr 22, 2021
3fc97ca
wrap vtk examples in app template
MarcSkovMadsen Apr 22, 2021
ad825e5
enable panel serve easily on binder
MarcSkovMadsen Apr 22, 2021
091d711
support running as app on binder
MarcSkovMadsen Apr 23, 2021
147405f
wrap into template for use on Binder
MarcSkovMadsen Apr 23, 2021
dbbc232
wrap into template for binder
MarcSkovMadsen Apr 23, 2021
5e0f86a
update notebooks
MarcSkovMadsen Apr 23, 2021
759eb62
fix dynamic tabs
MarcSkovMadsen Apr 23, 2021
0089789
wrap in template for binder
MarcSkovMadsen Apr 24, 2021
6103609
add app template for binder
MarcSkovMadsen Apr 24, 2021
4e4a882
wrap in template for binder
MarcSkovMadsen Apr 24, 2021
b124723
wrap in app template for Binder
MarcSkovMadsen Apr 24, 2021
01fc5d4
add interactive docs via voila
MarcSkovMadsen Apr 24, 2021
fe23c61
Fix #2248: Missing stapled line on FileInput
MarcSkovMadsen Apr 25, 2021
a176146
Wrap into app template for Binder
MarcSkovMadsen Apr 25, 2021
9b0cde3
Add app template for use on Binder
MarcSkovMadsen Apr 25, 2021
f21982a
Upgrade deck.gl js imports to make it compatible with other examples
MarcSkovMadsen Apr 25, 2021
c8883f3
Fixes #2249 and wraps into app template for binder
MarcSkovMadsen Apr 25, 2021
04d14f4
wrap in app template for Binder
MarcSkovMadsen Apr 25, 2021
2d125dc
Add app template for use on Binder
MarcSkovMadsen Apr 26, 2021
a2734d7
add app template for binder
MarcSkovMadsen Apr 28, 2021
f9a7bc3
refactor to pn.extension(sizing_mode="stretch_factor")
MarcSkovMadsen May 1, 2021
d265d35
Wrap in Template for binder
MarcSkovMadsen May 1, 2021
d3729c2
Merge branch 'master' of https://github.com/holoviz/panel into binder
May 2, 2021
4b562a7
fixed build errors #2280
May 2, 2021
7733494
Merge branch 'fix-build-errors' into binder
May 2, 2021
91d5bdf
Change default site_url for binder
MarcSkovMadsen May 2, 2021
4018e62
made responsive and added description to app
MarcSkovMadsen May 2, 2021
a63fbc1
added description to app
MarcSkovMadsen May 2, 2021
9ea973c
added description to app
MarcSkovMadsen May 2, 2021
369aa43
add description to apps
MarcSkovMadsen May 2, 2021
fbeacb2
Add description to app for Binder
MarcSkovMadsen May 2, 2021
9778751
Fix smaller app bugs
MarcSkovMadsen May 2, 2021
3317e98
get docs via voila working
MarcSkovMadsen May 2, 2021
eb433c5
help pip dependency resolved.
MarcSkovMadsen May 2, 2021
4a77848
Apply suggestions from code review
philippjfr May 3, 2021
219955e
Cleared notebook metadata
philippjfr May 3, 2021
2b33c3e
Fix flake
philippjfr May 3, 2021
656a461
Fix #2294: add requirements back. But in binder
May 5, 2021
0933be8
Fix coverage
philippjfr May 12, 2021
bed6e07
Apply suggestions from code review
philippjfr May 12, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
| Latest dev release | [![Github tag](https://img.shields.io/github/v/tag/holoviz/panel.svg?label=tag&colorB=11ccbb)](https://github.com/holoviz/panel/tags) [![dev-site](https://img.shields.io/website-up-down-green-red/https/pyviz-dev.github.io/panel.svg?label=dev%20website)](https://pyviz-dev.github.io/panel/) |
| Latest release | [![Github release](https://img.shields.io/github/release/holoviz/panel.svg?label=tag&colorB=11ccbb)](https://github.com/holoviz/panel/releases) [![PyPI version](https://img.shields.io/pypi/v/panel.svg?colorB=cc77dd)](https://pypi.python.org/pypi/panel) [![panel version](https://img.shields.io/conda/v/pyviz/panel.svg?colorB=4488ff&style=flat)](https://anaconda.org/pyviz/panel) [![conda-forge version](https://img.shields.io/conda/v/conda-forge/panel.svg?label=conda%7Cconda-forge&colorB=4488ff)](https://anaconda.org/conda-forge/panel) [![defaults version](https://img.shields.io/conda/v/anaconda/panel.svg?label=conda%7Cdefaults&style=flat&colorB=4488ff)](https://anaconda.org/anaconda/panel) |
| Docs | [![gh-pages](https://img.shields.io/github/last-commit/holoviz/panel/gh-pages.svg)](https://github.com/holoviz/panel/tree/gh-pages) [![site](https://img.shields.io/website-up-down-green-red/https/panel.holoviz.org.svg)](https://panel.holoviz.org) |
| Binder | [![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/holoviz/panel/binder?urlpath=lab/tree/examples) |
| Support | [![Discourse](https://img.shields.io/discourse/status?server=https%3A%2F%2Fdiscourse.holoviz.org)](https://discourse.holoviz.org/) |


## What is it?

Panel provides tools for easily composing widgets, plots, tables, and other viewable objects and controls into custom analysis tools, apps, and dashboards. Panel works with visualizations from [Bokeh](https://bokeh.pydata.org), [Matplotlib](https://matplotlib.org/), [HoloViews](https://holoviews.org), and many other Python plotting libraries, making them instantly viewable either individually or when combined with interactive widgets that control them. Panel works equally well in [Jupyter Notebooks](http://jupyter.org), for creating quick data-exploration tools, or as standalone deployed apps and dashboards, and allows you to easily switch between those contexts as needed.
Expand Down Expand Up @@ -50,7 +50,7 @@ Panel can be used in a wide range of development environments:

### Editor + Server

You can edit your Panel code as a .py file in any text editor, marking the objects you want to render as `.servable()`, then launch a server with `panel serve my_script.py --show` to open a browser tab showing your app or dashboard and backed by a live Python process.
You can edit your Panel code as a .py file in any text editor, marking the objects you want to render as `.servable()`, then launch a server with `panel serve my_script.py --show` to open a browser tab showing your app or dashboard and backed by a live Python process. If you want the server to automatically reload when you save code changes during development, then you should use `panel serve my_script.py --auto --show`.

### JupyterLab and Classic notebook

Expand Down
2 changes: 2 additions & 0 deletions binder/apt.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
libgl1-mesa-dev
xvfb
Empty file.
144 changes: 144 additions & 0 deletions binder/jupyter-panel-apps-server/examples-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
55 changes: 55 additions & 0 deletions binder/jupyter-panel-apps-server/jupyter_panel_apps_server.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
"""
Function to configure serving the panel example apps via jupyter-server-proxy.
"""
import pathlib
from glob import glob

ICON_PATH = str((pathlib.Path(__file__).parent / "examples-icon.svg").absolute())

DONT_SERVE = [
"examples/gallery/demos/attractors.ipynb",
"examples/gallery/demos/gapminders.ipynb",
"examples/gallery/demos/glaciers.ipynb",
"examples/gallery/demos/nyc_taxi.ipynb",
"examples/gallery/demos/portfolio-optimizer.ipynb",
]


def get_apps():
return [
app
for app in glob("examples/gallery/**/*.ipynb", recursive=True)
if not app in DONT_SERVE
]


def panel_serve_examples():
"""Returns the jupyter-server-proxy configuration for serving the example notebooks as Panel
apps.

Returns:
Dict: The configuration dictionary
"""
apps = get_apps()
# See:
# https://jupyter-server-proxy.readthedocs.io/en/latest/server-process.html
# https://github.com/holoviz/jupyter-panel-proxy/blob/master/panel_server/__init__.py
return {
"command": [
"panel",
"serve",
*apps,
"--allow-websocket-origin=*",
"--port",
"{port}",
"--prefix",
"{base_url}panel",
],
"absolute_url": True,
"timeout": 360,
"launcher_entry": {
"enabled": True,
"title": "Apps",
"icon_path": ICON_PATH,
},
}
14 changes: 14 additions & 0 deletions binder/jupyter-panel-apps-server/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
"""This setup.py will install a package that configures the jupyter-server-proxy to
panel serve the example notebooks."""
import setuptools

setuptools.setup(
name="jupyter-panel-examples-server",
py_modules=["jupyter_panel_apps_server"],
entry_points={
"jupyter_serverproxy_servers": [
"panel = jupyter_panel_apps_server:panel_serve_examples",
]
},
install_requires=["jupyter-server-proxy", "panel"],
)
Empty file.
Loading