Skip to content

Commit

Permalink
chore(docs): avoid downloading files in jupyterlite setup
Browse files Browse the repository at this point in the history
  • Loading branch information
cpcloud committed Jan 18, 2025
1 parent 4dc8631 commit 86c8dba
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 0 additions & 6 deletions docs/tutorials/browser/repl.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,6 @@ Please [open an issue on GitHub](https://github.com/ibis-project/ibis/issues/new
from urllib.parse import urlencode
lines = """
import pathlib, js
penguins_csv_url = "https://storage.googleapis.com/ibis-tutorial-data/penguins.csv"
penguins_text = await (await js.fetch(penguins_csv_url)).text()
pathlib.Path("penguins.csv").write_text(penguins_text)
del pathlib, js, penguins_csv_url, penguins_text
%clear
%pip install 'ibis-framework[duckdb]'
from ibis.interactive import *
penguins = ibis.read_csv("penguins.csv")
Expand Down
3 changes: 3 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -302,12 +302,15 @@ build-jupyterlite:
--arg ibis "dist/ibis_framework-${ibis_dev_version}-py3-none-any.whl" \
> jupyter_lite_config.json

curl -SLsO https://storage.googleapis.com/ibis-tutorial-data/penguins.csv
jupyter lite build \
--debug \
--contents penguins.csv \
--no-libarchive \
--apps repl \
--no-unused-shared-packages \
--output-dir docs/_output/jupyterlite
rm -f penguins.csv
# jupyter lite build can copy from the nix store, and preserves the
# original write bit; without this the next run of this rule will result in
# a permission error when the build tries to remove existing files
Expand Down

0 comments on commit 86c8dba

Please sign in to comment.