Skip to main content

async-kernel

pypi downloads CI Ruff uv basedpyright - checked Built with Material for MkDocs codecov

logo-svg

async-kernel provides Python Jupyter kernels and clients compatible with CPython (Jupyter & VS code) and Pyodide (Jupyterlite).

The kernel interface supports multiple connections including:

  1. Messaging via ZMQ sockets (Jupyter, VS Code, etc).
  2. Same-process local client enabling (Jupyterlite) and user access.

Highlights

  • Built using aiologic thread-safe synchronisation primitives.
  • The Caller class provides a powerful but simple interface for cross-thread code execution in asyncio and trio backends, with guest event loop support built in.
  • A zmq poll event loop for thread-safe zmq sockets.
  • IPython shell
    • top-level await ('asyncio' or 'trio' backend) in cells
    • async magic function support in cells
  • Per-subshell user_ns
  • GUI event loops 1
    • inline
    • ipympl
    • tk host and asyncio2 or trio3 backend running as a guest
    • qt host and asyncio2 or trio3 backend running as a guest
  • Experimental support for Jupyterlite (try it online here 👈)
    • %pip install magic (using micropip)
  • Debugger client
  • Local client.
  • ZMQ client.

Installation

pip install async-kernel

Kernelspecs

A kernelspec with the name 'async' is added when async-kernel is installed.

Kernel specs can be installed/uninstalled via the command line.

async-kernel install

# To install for a user
async-kernel install --user

For further detail about kernel spec customisation see command line and kernel configuration and custom kernel.ipynb.

Faster data serialization

orjson (a fast JSON library) is supported and will be used by default if it has been installed.

Free-threading support

async-kernel's Caller's are thread-local and it's methods are internally synchronised4.

Origin

async-kernel started as a fork of IPyKernel. Thank you to the original contributors of IPyKernel that made async-kernel possible.

  1. A gui (host) enabled kernel interface starts a gui's mainloop (host) which starts the backend as a guest, then finally the Kernel is started.

  2. The asyncio implementation of start_guest_run was written by the author of aiologic and provided as a gist. 2

  3. trio's start_guest_run. 2

  4. free threading terminology

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

async_kernel-0.22.2.tar.gz (359.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

async_kernel-0.22.2-py3-none-any.whl (135.4 kB view details)

Uploaded Python 3

File details

Details for the file async_kernel-0.22.2.tar.gz.

File metadata

  • Download URL: async_kernel-0.22.2.tar.gz
  • Upload date:
  • Size: 359.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for async_kernel-0.22.2.tar.gz
Algorithm Hash digest
SHA256 12f1350f9a24084ae926d5f8f93c738312f9d84fdc83d83b398ac2bce578a0c0
MD5 c817ce55f13ed35feb1099fe020d0c0b
BLAKE2b-256 947ec5a389929429fcbc8f6961f8d8dceba22ad69c442f6a5280ba47eaba6866

See more details on using hashes here.

Provenance

The following attestation bundles were made for async_kernel-0.22.2.tar.gz:

Publisher: publish-to-pypi.yml on fleming79/async-kernel

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file async_kernel-0.22.2-py3-none-any.whl.

File metadata

  • Download URL: async_kernel-0.22.2-py3-none-any.whl
  • Upload date:
  • Size: 135.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for async_kernel-0.22.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4644d9a709a6caa679c54d98ac80c7f143e21cb8f29ba63c006c294a3529c093
MD5 1afd101d839cfef5f800757a2162e568
BLAKE2b-256 6547ae7a9e9f8fde8c4eeafade8428fd8375dd6648e05872bb0363dc8a6f7ae2

See more details on using hashes here.

Provenance

The following attestation bundles were made for async_kernel-0.22.2-py3-none-any.whl:

Publisher: publish-to-pypi.yml on fleming79/async-kernel

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.22.3

2 files

This release

0.22.2 This release

2 files

0.22.1

2 files

0.22.0

2 files

0.21.0

2 files

0.20.2

2 files

0.20.1

2 files

0.20.0

2 files

0.19.2

2 files

0.19.1

2 files

0.19.0

2 files

0.18.3

2 files

0.18.2

2 files

0.18.1

2 files

0.18.0

2 files

0.17.1

2 files

0.17.0

2 files

0.16.4

2 files

0.16.3

2 files

0.16.2

2 files

0.16.1

2 files

0.16.0

2 files

0.15.0

2 files

0.14.0

2 files

0.13.3

2 files

0.13.2

2 files

0.13.1

2 files

0.13.0

2 files

0.12.5

2 files

0.12.4

2 files

0.12.3

2 files

0.12.2

2 files

0.12.1

2 files

0.12.0

2 files

0.11.2

2 files

0.11.1

2 files

0.11.0

2 files

0.10.3

2 files

0.10.2

2 files

0.10.1

2 files

0.10.0

2 files

0.9.2

2 files

0.9.1

2 files

0.9.0

2 files

0.8.0

2 files

0.7.2

2 files

0.7.1

2 files

0.7.0

2 files

0.7.0rc1

2 files

0.6.3

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.4

2 files

0.5.3

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.1

2 files

0.2.0

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page