-
-
Notifications
You must be signed in to change notification settings - Fork 18.2k
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
Add a JupyterLite-powered interactive shell for the pandas
website (reprise of #47428)
#60758
base: main
Are you sure you want to change the base?
Add a JupyterLite-powered interactive shell for the pandas
website (reprise of #47428)
#60758
Conversation
Co-Authored-By: Jeremy Tuloup <jtp@jtp.io>
Co-Authored-By: Jeremy Tuloup <jtp@jtp.io>
cc @datapythonista if you're interested in taking a look, I plan to review in the next few days. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR!
You can try pandas in your browser with the following interactive shell | ||
without needing to install anything on your system. | ||
|
||
**Please note it can take a while before the shell is initialised and ready to run commands.** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of a while
can we give a estimate of how long.
|
||
**Running it requires a reasonable amount of bandwidth and resources, so it may not work properly on all devices or networks.** | ||
|
||
<iframe |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will start loading on the Getting Started page, is that right? If so, I think we should perhaps move to its own page so that users don't have to spend the bandwidth.
# which in-turn comes with pandas 2.2.3: | ||
# 1. https://jupyterlite-pyodide-kernel.readthedocs.io/en/stable/#compatibility | ||
# 2. https://pyodide.org/en/stable/usage/packages-in-pyodide.html | ||
# We constrain/pin here to avoid breaking changes on rebuilds. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We typically do not do this because hard pinning for some time and then doing a major upgrade is often harder than addressing each break as it comes in. Is there a reason we should take a different approach here?
# Pyodide kernel version 0.5.2 comes with Pyodide 0.27.1 | ||
# which in-turn comes with pandas 2.2.3: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what this comment is attempting to convey - is there a reason this is important? Also, not sure if it's relevant but what comes with pandas 2.2.3 doesn't seem important here; this is used for dev envs, not releases.
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.This pull request aims to reinstate the machinery for adding a JupyterLite shell for the
pandas
website, based on discussions in #60747 and on Slack, please see them for a rationale on this change (short answer: it's been a while in 2025 and things might be smoother now).An interactive shell was first discussed in #46682 and later removed in #49807. There was a request to reinstate this in #49807 (comment) which might not have been noticed, so I hope #60747 and this PR bring more visibility to the proposal.
In particular, this PR adds back the previous changes from #47428, with only minor differences in the configuration. I've used (and pinned) the
jupyterlite-pyodide-kernel
for the REPL, which in-turn provides Pyodide version 0.5.2, which comes withpandas
version 2.2.3.The differences in the changes from the previous PR are as follows:
jupyterlite-pyodide-kernel
have been incorporated, i.e., 0.5.0 and 0.5.2 respectivelyAs mentioned in #60747, it is also possible to use the https://jupyterlite.github.io/demo/ REPL in the iframe to remove dependencies, however, it would come at the cost of disabled optimisations and a general lack of control for how the REPL is built.
cc: @jtpio, please feel free to add any suggestions!