Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

emscripten-forge/sample-python-repl

Repository files navigation

sample-python-repl

A demo repository for create a Python REPL that runs in the browser.

a screenshot showing the Pyhon REPL in the browser

Try it in your browser

You can try the Python REPL in your browser at the following URL: https://emscripten-forge.github.io/sample-python-repl

Requirements

You will need to install micromamba to build the application.

Usage

First clone the repository:

git clone https://github.com/emscripten-forge/sample-python-repl
cd sample-python-repl

Then create a new environment that will be used for building the REPL:

# create the environment
micromamba create -n pyjs-build-env -f build-environment.yaml -y
# activate the environment
micromamba activate pyjs-build-env

In the environment, run the build script:

python build.py

This create a new environment that will include the dependencies for running the REPL in the browser (runtime). The script also copies the relevant files to the build folder.

You can then start an HTTP server to serve the files in the build folder:

python -m http.server --directory build

And open the REPL in your browser at http://localhost:8000.

Releases

No releases published

Packages

No packages published

Contributors 2

AltStyle によって変換されたページ (->オリジナル) /