{"id":21344618,"url":"https://github.com/promplate/pyth-on-line","last_synced_at":"2025-07-12T15:32:11.042Z","repository":{"id":224904225,"uuid":"764548401","full_name":"promplate/pyth-on-line","owner":"promplate","description":"Online Python IDE with built-in Copilot","archived":false,"fork":false,"pushed_at":"2025-06-25T00:44:18.000Z","size":635,"stargazers_count":12,"open_issues_count":59,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-25T01:40:52.264Z","etag":null,"topics":["console","copilot","ide","pyodide","svelte","wasm"],"latest_commit_sha":null,"homepage":"https://pyth-on-line.netlify.app/about","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/promplate.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-28T09:27:16.000Z","updated_at":"2025-06-25T00:43:14.000Z","dependencies_parsed_at":"2024-04-19T13:44:09.654Z","dependency_job_id":"9e0f44d8-92a9-481c-94d1-211c7b67448b","html_url":"https://github.com/promplate/pyth-on-line","commit_stats":null,"previous_names":["promplate/pyth-on-line"],"tags_count":52,"template":false,"template_full_name":null,"purl":"pkg:github/promplate/pyth-on-line","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/promplate%2Fpyth-on-line","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/promplate%2Fpyth-on-line/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/promplate%2Fpyth-on-line/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/promplate%2Fpyth-on-line/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/promplate","download_url":"https://codeload.github.com/promplate/pyth-on-line/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/promplate%2Fpyth-on-line/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263150609,"owners_count":23421594,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["console","copilot","ide","pyodide","svelte","wasm"],"created_at":"2024-11-22T01:20:39.831Z","updated_at":"2025-07-12T15:32:10.683Z","avatar_url":"https://github.com/promplate.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Introducing Pythonline\n\nPythonline is a Python interpreter that runs in your browser. It is based on the [Pyodide](https://github.com/pyodide/pyodide) project, which is a WASM build of CPython.\n\nWith Pythonline, you can easily share your Python snippets with others, without the need to install Python on their local machine. You can also use it to run Python code on your phone or tablet, without the need to install any apps. Let's take the `math` module as an example:\n\n```python\n\u003e\u003e\u003e import math\n\u003e\u003e\u003e math.pi\n```\n\nIf you hover over the code block above, you will see a button to run the code.\nAfter that, you can inspect these values by hovering over them 👇\n\n| Kind           | Examples                                      |\n| -------------- | --------------------------------------------- |\n| Global Names   | `_`, `__name__`, `int`, `Exception`           |\n| Literal Values | `[{}]`, `1,2`, `1+2j`, `.0`, `0b10`           |\n| Expressions    | `math.pi / 2`                                 |\n| Assignments    | `one = -(math.e ** complex(0, math.pi)).real` |\n\n## Main Features\n\nYou can use top-level await:\n\n```python\nfrom asyncio import sleep\n\nfor i in range(10):\n    print(i, end=\" \")\n    await sleep(0.1)\n```\n\nNative and informative traceback:\n\n```python\ndef reciprocal(x: int):\n    return 1 / x\n```\n\nTry this:\n\n```python\n1 + reciprocal(0)\n```\n\n## Basic Usage\n\nPyodide supports [a large subset of the Python standard library](https://pyodide.org/en/stable/usage/wasm-constraints.html). You can use all of them here.\nIt also supports all pure-python libs or [adapted hybrid libs](https://pyodide.org/en/stable/usage/packages-in-pyodide.html) such as famous scientific libraries like NumPy, Pandas, SciPy, SciKit-Learn, etc.\n\nFurthermore, you can use global variables like `navigator` from the `window` scope by:\n\n```python\nfrom js import navigator\n\nprint(navigator.languages)\nawait navigator.clipboard.readText()\n```\n\nLet's try invoking web requests:\n\n```python\nfrom asyncio import gather\nfrom pyodide.http import pyfetch  # which is just a wrapper on the fetch in js\n\nasync def f(url):\n    res = await pyfetch(url, method=\"HEAD\", cache=\"no-store\")\n    print(res.status, res.status_text, res.headers.get(\"content-type\"))\n    return res.ok\n\nawait gather(*(f(\".\") for _ in range(10)))\n```\n\n\u003e This project is still work in progress for now, so feel free to [get in touch](https://github.com/promplate/pyth-on-line/discussions) if you have any feedback or suggestions!\n\n## Acknowledgements\n\n- This project is heavily inspired by [StackBlitz](https://stackblitz.com/), [CodePen](https://codepen.io/) and [Marimo](https://github.com/marimo-team/marimo)\n- Developers from [pyodide](https://github.com/pyodide) helped me a lot\n- There are some other similar projects like [futurecoder](https://futurecoder.io/), [JupyterLite](https://jupyterlite.github.io/demo) and [PyScript](https://pyscript.com/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpromplate%2Fpyth-on-line","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpromplate%2Fpyth-on-line","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpromplate%2Fpyth-on-line/lists"}