Contribute Media
A thank you to everyone who makes this possible: Read More

A CPython Eating Its Own Tail

Description

This is an expert-level talk that dives into CPython and discusses various ways to embed Python interpreters. It starts with the "very high level" embedding & the "pure" embedding, shows a fairly novel "zero interpreter" embedding using Cython, a few attempts at a ctypes/cffi embedding, and builds to a finish with a source-filter embedding of a Python interpreter into itself.

The purpose of this talk is to have some fun diving into CPython internals while looking practical approaches to embedding CPython interpreters into other (C/C++) processes. The final result, a Python 3 interpreter embedded into a Python 2 interpreter as an extension model, is novel but may be of fairly limited actual use. It is, however, pretty wild and a lot of fun!

Details

Improve this page