Skip to content

Commit

Permalink
Stitch update to fix NPM issues. (#1118)
Browse files Browse the repository at this point in the history
Release to 0.1.1 for stitch to fix some NPM remote pathing issues.

---------

Co-authored-by: Paul Koch <46825734+paulbkoch@users.noreply.github.com>
  • Loading branch information
nopdive and paulbkoch authored Feb 10, 2025
1 parent 315b388 commit 7e29ed6
Show file tree
Hide file tree
Showing 11 changed files with 58 additions and 58 deletions.
8 changes: 4 additions & 4 deletions packages/python/stitch/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ Bidirectional comms for Jupyter and JavaScript.
You can install using `pip`:

```bash
pip install stitch
pip install guidance-stitch
```

If you are using Jupyter Notebook 5.2 or earlier, you may also need to enable
the nbextension:
```bash
jupyter nbextension enable --py [--sys-prefix|--user|--system] stitch
jupyter nbextension enable --py [--sys-prefix|--user|--system] guidance-stitch
```

## Development Installation
Expand All @@ -45,8 +45,8 @@ jlpm run build
For classic notebook, you need to run:

```
jupyter nbextension install --sys-prefix --symlink --overwrite --py stitch
jupyter nbextension enable --sys-prefix --py stitch
jupyter nbextension install --sys-prefix --symlink --overwrite --py guidance-stitch
jupyter nbextension enable --sys-prefix --py guidance-stitch
```

Note that the `--symlink` flag doesn't work on Windows, so you will here have to run
Expand Down
2 changes: 1 addition & 1 deletion packages/python/stitch/docs/source/installing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ notebook (as opposed to Jupyterlab), run::
with the `appropriate flag`_. If you are using Jupyterlab, install the extension
with::

jupyter labextension install stitch
jupyter labextension install @guidance-ai/stitch

If you are installing using conda, these commands should be unnecessary, but If
you need to run them the commands should be the same (just make sure you choose the
Expand Down
4 changes: 2 additions & 2 deletions packages/python/stitch/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "stitch",
"version": "0.1.0",
"name": "@guidance-ai/stitch",
"version": "0.1.2",
"description": "Bidirectional comms for Jupyter and JavaScript.",
"keywords": [
"jupyter",
Expand Down
8 changes: 4 additions & 4 deletions packages/python/stitch/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ classifiers = [
dependencies = [
"ipywidgets>=8.0.0",
]
version = "0.1.0"
version = "0.1.2"

[project.optional-dependencies]
docs = [
Expand Down Expand Up @@ -75,8 +75,8 @@ packages = ["stitch"]

[tool.hatch.build.targets.wheel.shared-data]
"stitch/nbextension" = "share/jupyter/nbextensions/stitch"
"stitch/labextension" = "share/jupyter/labextensions/stitch"
"./install.json" = "share/jupyter/labextensions/stitch/install.json"
"stitch/labextension" = "share/jupyter/labextensions/@guidance-ai/stitch"
"./install.json" = "share/jupyter/labextensions/@guidance-ai/stitch/install.json"
"./stitch.json" = "etc/jupyter/nbconfig/notebook.d/stitch.json"

[tool.hatch.build.targets.sdist]
Expand Down Expand Up @@ -114,7 +114,7 @@ file = [
]

[tool.tbump.version]
current = "0.1.0.dev0"
current = "0.1.1"
regex = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)((?P<channel>a|b|rc|.dev)(?P<release>\\d+))?"

[tool.tbump.git]
Expand Down
2 changes: 1 addition & 1 deletion packages/python/stitch/src/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import * as widgetExports from './widget';

import { MODULE_NAME, MODULE_VERSION } from './version';

const EXTENSION_ID = 'stitch:plugin';
const EXTENSION_ID = '@guidance-ai/stitch:plugin';

/**
* The example plugin.
Expand Down
2 changes: 1 addition & 1 deletion packages/python/stitch/stitch/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def _jupyter_labextension_paths():
"""
return [{
'src': 'labextension',
'dest': 'stitch',
'dest': '@guidance-ai/stitch',
}]


Expand Down
4 changes: 2 additions & 2 deletions packages/python/stitch/stitch/_frontend.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@
Information about the frontend package of the widgets.
"""

module_name = "stitch"
module_version = "^0.1.0"
module_name = "@guidance-ai/stitch"
module_version = "^0.1.1"
2 changes: 1 addition & 1 deletion packages/python/stitch/stitch/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# Copyright (c) Guidance Contributors.
# Distributed under the terms of the Modified BSD License.

version_info = (0, 1, 0)
version_info = (0, 1, 2)
__version__ = ".".join(map(str, version_info))
2 changes: 1 addition & 1 deletion packages/python/stitch/stitch/nbextension/extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ define(function() {
window['requirejs'].config({
map: {
'*': {
'stitch': 'nbextensions/stitch/index',
'@guidance-ai/stitch': 'nbextensions/stitch/index',
},
}
});
Expand Down
6 changes: 3 additions & 3 deletions packages/python/stitch/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ module.exports = [
},

/**
* Embeddable stitch bundle
* Embeddable @guidance-ai/stitch bundle
*
* This bundle is almost identical to the notebook extension bundle. The only
* difference is in the configuration of the webpack public path for the
Expand All @@ -55,8 +55,8 @@ module.exports = [
filename: 'index.js',
path: path.resolve(__dirname, 'dist'),
libraryTarget: 'amd',
library: "stitch",
publicPath: 'https://unpkg.com/stitch@' + version + '/dist/'
library: "@guidance-ai/stitch",
publicPath: 'https://unpkg.com/@guidance-ai/stitch@' + version + '/dist/'
},
devtool: 'source-map',
module: {
Expand Down
76 changes: 38 additions & 38 deletions packages/python/stitch/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1332,6 +1332,44 @@ __metadata:
languageName: node
linkType: hard

"@guidance-ai/stitch@workspace:.":
version: 0.0.0-use.local
resolution: "@guidance-ai/stitch@workspace:."
dependencies:
"@babel/core": ^7.23.7
"@babel/preset-env": ^7.23.8
"@jupyter-widgets/base": ^1.1.10 || ^2 || ^3 || ^4 || ^5 || ^6
"@jupyter-widgets/base-manager": ^1.0.7
"@jupyterlab/builder": ^4.0.11
"@lumino/application": ^2.3.0
"@lumino/widgets": ^2.3.1
"@types/jest": ^29.5.11
"@types/webpack-env": ^1.18.4
"@typescript-eslint/eslint-plugin": ^6.19.1
"@typescript-eslint/parser": ^6.19.1
acorn: ^8.11.3
css-loader: ^6.9.1
eslint: ^8.56.0
eslint-config-prettier: ^9.1.0
eslint-plugin-prettier: ^5.1.3
fs-extra: ^11.2.0
identity-obj-proxy: ^3.0.0
jest: ^29.7.0
jest-environment-jsdom: ^29.7.0
mkdirp: ^3.0.1
npm-run-all: ^4.1.5
prettier: ^3.2.4
rimraf: ^5.0.5
source-map-loader: ^5.0.0
style-loader: ^3.3.4
ts-jest: ^29.1.2
ts-loader: ^9.5.1
typescript: ~5.3.3
webpack: ^5.90.0
webpack-cli: ^5.1.4
languageName: unknown
linkType: soft

"@humanwhocodes/config-array@npm:^0.13.0":
version: 0.13.0
resolution: "@humanwhocodes/config-array@npm:0.13.0"
Expand Down Expand Up @@ -7799,44 +7837,6 @@ __metadata:
languageName: node
linkType: hard

"stitch@workspace:.":
version: 0.0.0-use.local
resolution: "stitch@workspace:."
dependencies:
"@babel/core": ^7.23.7
"@babel/preset-env": ^7.23.8
"@jupyter-widgets/base": ^1.1.10 || ^2 || ^3 || ^4 || ^5 || ^6
"@jupyter-widgets/base-manager": ^1.0.7
"@jupyterlab/builder": ^4.0.11
"@lumino/application": ^2.3.0
"@lumino/widgets": ^2.3.1
"@types/jest": ^29.5.11
"@types/webpack-env": ^1.18.4
"@typescript-eslint/eslint-plugin": ^6.19.1
"@typescript-eslint/parser": ^6.19.1
acorn: ^8.11.3
css-loader: ^6.9.1
eslint: ^8.56.0
eslint-config-prettier: ^9.1.0
eslint-plugin-prettier: ^5.1.3
fs-extra: ^11.2.0
identity-obj-proxy: ^3.0.0
jest: ^29.7.0
jest-environment-jsdom: ^29.7.0
mkdirp: ^3.0.1
npm-run-all: ^4.1.5
prettier: ^3.2.4
rimraf: ^5.0.5
source-map-loader: ^5.0.0
style-loader: ^3.3.4
ts-jest: ^29.1.2
ts-loader: ^9.5.1
typescript: ~5.3.3
webpack: ^5.90.0
webpack-cli: ^5.1.4
languageName: unknown
linkType: soft

"string-length@npm:^4.0.1":
version: 4.0.2
resolution: "string-length@npm:4.0.2"
Expand Down

0 comments on commit 7e29ed6

Please sign in to comment.