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

Update JupyterLite deployment and docs #87

Merged
merged 4 commits into from
Aug 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
11 changes: 5 additions & 6 deletions docs/build-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ dependencies:
- mamba
- myst-parser
- pydata-sphinx-theme
- python=3.9
- python
- jupyterlab-blockly
- pip:
- jupyterlab-blockly
# Remove all pinning when we support jupyterlab v4 in jupyterlab-blockly
- jupyterlite-core===0.1.3
- jupyterlite-sphinx===0.9.3
- jupyterlite-xeus===0.1.8
- jupyterlite-core
- jupyterlite-sphinx
- jupyterlite-xeus
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
author = 'Denisa Checiu'

# The full version, including alpha/beta/rc tags
release = '0.1.0'
release = '0.3.0'


# -- General configuration ---------------------------------------------------
Expand Down
39 changes: 1 addition & 38 deletions docs/other_extensions.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,43 +111,6 @@ const plugin: JupyterFrontEndPlugin<void> = {
**NOTE** : `BlocklyNiryo` is defined in `niryo-one-python-generators.ts`.


## Include patches
Currently, for the extension to work, you will need to include the following patch from the JupyterLab-Blockly extension (make sure it is placed in a file named `@jupyterlab+codeeditor+3.4.3.patch`, inside the `patches` folder):

```
// patches/@jupyterlab+codeeditor+3.4.3.patch

diff --git a/node_modules/@jupyterlab/codeeditor/lib/editor.d.ts b/node_modules/@jupyterlab/codeeditor/lib/editor.d.ts
index ffe8d1f..d63b2f8 100644
--- a/node_modules/@jupyterlab/codeeditor/lib/editor.d.ts
+++ b/node_modules/@jupyterlab/codeeditor/lib/editor.d.ts
@@ -44,7 +44,7 @@ export declare namespace CodeEditor {
/**
* An interface describing editor state coordinates.
*/
- interface ICoordinate extends JSONObject, ClientRect {
+ interface ICoordinate extends JSONObject {
}
/**
* A range.
```

You will also need to modify the `MANIFEST.in` file:
```
recursive-include patches *.patch
```
the `package.json` file:
```
"scripts": {
...
"postinstall": "patch-package"
}
````
and, finally, add `patch-package` as a dependency:
```
jlpm add patch-package
```

## Additional configurations

You will need to request the `jupyterlab-blockly` package as a dependency of your extension, in order to ensure it is installed and available to provide the token `IBlocklyRegistry`. To do this, you need to add the following line to your `setup.py` file.
Expand All @@ -157,7 +120,7 @@ You will need to request the `jupyterlab-blockly` package as a dependency of you

setup_args = dict(
...
install_requires=['jupyterlab-blockly>=0.1.1,<0.2']
install_requires=['jupyterlab-blockly>=0.3.0,<0.4']
...
)
```
Expand Down
Loading