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

Fix broken JupyterWidget chart by pinning Vega #3269

Merged
merged 2 commits into from
Nov 23, 2023
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
9 changes: 9 additions & 0 deletions NOTES_FOR_MAINTAINERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,15 @@ of some docstrings.
Major version updates (e.g. Vega-Lite 1.X->2.X) have required substantial
rewrites, because the internal structure of the schema changed appreciably.

## Updating the Vega-Lite in JupyterChart
To update the Vega-Lite version used in JupyterChart, update the version in the esm.sh URL in `altair/jupyter/js/index.js`.

For example, to update to Vega-Lite 5.15.1, Vega 5 and Vega-Embed 6, the URL should be:

```javascript
import embed from "https://esm.sh/vega-embed@6?deps=vega@5&[email protected]";
```

### Updating vl-convert version bound
When updating the version of Vega-Lite, it's important to ensure that
[vl-convert](https://github.com/vega/vl-convert) includes support for the new Vega-Lite version.
Expand Down
4 changes: 2 additions & 2 deletions altair/jupyter/js/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import embed from "https://cdn.jsdelivr.net/npm/vega-embed@6/+esm";
import debounce from "https://cdn.jsdelivr.net/npm/[email protected]/debounce/+esm";
import embed from "https://esm.sh/vega-embed@6?deps=vega@5&[email protected]";
import debounce from "https://esm.sh/[email protected]/debounce";

export async function render({ model, el }) {
let finalize;
Expand Down