Skip to content

Latest commit

 

History

History
108 lines (61 loc) · 2.86 KB

install.rst

File metadata and controls

108 lines (61 loc) · 2.86 KB

Install RobotKernel

Installing RobotKernel requires Python 3.6 or later and Robot Framework 3.1 or later.

Virtualenv installation

RobotKernel can be installed using the usual Python package manager tools, like pip:

$ pip install robotkernel

For JupyterLab you should also install the companion syntax highlighting and Jupyter widgets support:

$ jupyter labextension install jupyterlab_robotmode
$ jupyter labextension install @jupyter-widgets/jupyterlab-manager

For some environments it might be required to run the following command to manually register robotkernel as Jupyter kernel:

$ python -m robotkernel.install

Install Robotkernel from Python 3 notebook

!pip install robotkernel

After refreshing the notebook, it is possible change the kernel to Robot Framework kernel or create a new notebook with Robot Framework kernel.

For JupyterLab you should also install the companion syntax highlighting and Jupyter widgets support:

!jupyter labextension install jupyterlab_robotmode
!jupyter labextension install @jupyter-widgets/jupyterlab-manager

Local installation and development

See also: http://jupyter.readthedocs.io/en/latest/install.html

Create and activate clean Python virtual environment:

$ venv myenv
$ source myenv/bin/activate

Install Jupyter:

$ pip install --upgrade pip setuptools
$ pip install jupyter

Clone this kernel:

$ git clone https://github.com/robots-from-jupyter/robotkernel.git
$ cd robotkernel

Install the kernel into virtualenv in develop mode:

$ python setup.py develop

Launch the jupyter:

$ jupyter notebook

Reloading the kernel reloads the code.

This repository includes opinionated instructions for running and developing Robotkernel with Nix for Jupyter Notebook:

$ nix-shell -E 'import (fetchTarball https://github.com/robots-from-jupyter/robotkernel/archive/master.tar.gz + "/shell.nix")' --run "jupyter notebook"

And for Jupyter Lab:

$ nix-shell -E 'import (fetchTarball https://github.com/robots-from-jupyter/robotkernel/archive/master.tar.gz + "/shell.nix")'
$ jupyter labextension install jupyterlab_robotmode --app-dir=.jupyterlab
$ jupyter lab --app-dir=.jupyterlab
$ exit

Add --arg vim true to enable vim bindings for Jupyter Notebook.

Development environment with Nix:

$ git clone https://github.com/robots-from-jupyter/robotkernel.git
$ cd robotkernel
$ nix-build setup.nix -A env  # to generate ./result/bin/python for IDE
$ nix-shell setup.nix -A develop