Metadata-Version: 2.4
Name: jupyhai
Version: 2.0.0b2
Summary: Jupyter notebook / JupyterLab extension to execute notebooks remotely on Minihai or Valohai host.
Project-URL: Homepage, https://github.com/valohai/jupyhai
Author-email: valohai <info@valohai.com>
License-Expression: MIT
Keywords: Jupyter,JupyterLab,JupyterLab3
Classifier: Framework :: Jupyter
Classifier: Framework :: Jupyter :: JupyterLab
Classifier: Framework :: Jupyter :: JupyterLab :: 3
Classifier: Framework :: Jupyter :: JupyterLab :: Extensions
Classifier: Framework :: Jupyter :: JupyterLab :: Extensions :: Prebuilt
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Requires-Dist: aiohttp~=3.9
Requires-Dist: pydantic~=2.0
Requires-Dist: valohai-cli>=0.26.0
Requires-Dist: valohai-utils>=0.3.0
Requires-Dist: valohai-yaml>=0.23.0
Provides-Extra: lab
Requires-Dist: jupyterlab~=4.0; extra == 'lab'
Provides-Extra: nbclassic
Requires-Dist: nbclassic~=1.0; extra == 'nbclassic'
Provides-Extra: notebook
Requires-Dist: notebook~=7.0; extra == 'notebook'
Provides-Extra: test
Requires-Dist: pytest-cov~=4.1; extra == 'test'
Requires-Dist: pytest~=7.4; extra == 'test'
Description-Content-Type: text/markdown

# Jupyhai

Valohai extension for Jupyter Notebook & JupyterLab

## Developing

If you have a local Valohai instance running, or are developing against a private Valohai installation,
set the `VALOHAI_HOST` environment variable to point at that instance
(e.g. `export VALOHAI_HOST=http://127.0.0.1:8000/`).

### Installation (dev)

```bash
# Create and activate a python 3 virtualenv
python3 -m venv venv
source venv/bin/activate

pip install -e .
pip install jupyterlab
jupyhai install
```

### Running (dev)

```bash
# notebook extension
yarn watch:nbextension
# lab extension
yarn watch:labextension
```

And in another tab...

```
jupyter notebook
jupyter lab
```

### Updating Dependencies

To update the JavaScript dependencies, edit the `package.json` file and run:

```bash
jlpm
```

## Testing

### Running docker

```bash
make build-docker run-docker
```

### Running Python tests

```bash
py.test --cov .
```

### Running JavaScript tests

```bash
yarn jest --coverage --coverageReporters=html --coverageReporters=text
```

## Deploying

### Deployment

#### Deploying the Jupyhai notebook image

```bash
make build-docker
docker push valohai/jupyhai
```

#### Deploying the Jupyhai wheel

```bash
make build-wheel
# Docker magic occurs!
# Creates ./build/[generatedfilename].whl

# On client machine:
pip install ./[generatedfilename].whl
jupyhai install
```

### Publishing a wheel

```bash
make build-wheel
twine upload build/*.whl
```
