Ship full CPython (python3) for a full-featured guest python#7
Merged
Conversation
The guest needs a full-featured Python: the migrated test suite (and real debugging use) requires ctypes (FFI for libc calls / ioctl), mmap, fcntl, socket, ssl, sqlite3 -- none of which python3Minimal builds. Switch to the full python3 interpreter. Verified x86_64: lib-dynload now includes _ctypes, fcntl, mmap, _socket, _ssl, _sqlite3 (77 modules vs 63), and the bundle still passes the runtime link-closure check (the new libs are staged into dylibs).
lacraig2
added a commit
to rehosting/penguin
that referenced
this pull request
Jun 9, 2026
hyperfs (which provided /igloo/utils/micropython) is gone, so the 9 tests
that used it now run on penguin-tools' CPython at /igloo/utils/python3:
- uos -> os; usocket -> socket
- ffilib/uctypes mmap -> the CPython `mmap` module (native_mmap, devfs
mmap_custom, pseudofile_mmap_{shared,private,rw})
- ffilib open/ioctl -> os.open + fcntl.ioctl (pseudofiles_comprehensive)
- ffi libc/lib_inject calls -> ctypes (uprobes, proc_mtd_dynamic)
Requires the full CPython (ctypes/mmap/fcntl/socket), so bump
PENGUIN_TOOLS_VERSION to 0.0.6 (rehosting/penguin-tools#7).
lacraig2
added a commit
to rehosting/penguin
that referenced
this pull request
Jun 9, 2026
hyperfs (which provided /igloo/utils/micropython) is gone, so the 9 tests
that used it now run on penguin-tools' CPython at /igloo/utils/python3:
- uos -> os; usocket -> socket
- ffilib/uctypes mmap -> the CPython `mmap` module (native_mmap, devfs
mmap_custom, pseudofile_mmap_{shared,private,rw})
- ffilib open/ioctl -> os.open + fcntl.ioctl (pseudofiles_comprehensive)
- ffi libc/lib_inject calls -> ctypes (uprobes, proc_mtd_dynamic)
Requires the full CPython (ctypes/mmap/fcntl/socket), so bump
PENGUIN_TOOLS_VERSION to 0.0.6 (rehosting/penguin-tools#7).
lacraig2
added a commit
to rehosting/penguin
that referenced
this pull request
Jun 9, 2026
hyperfs (which provided /igloo/utils/micropython) is gone, so the 9 tests
that used it now run on penguin-tools' CPython at /igloo/utils/python3:
- uos -> os; usocket -> socket
- ffilib/uctypes mmap -> the CPython `mmap` module (native_mmap, devfs
mmap_custom, pseudofile_mmap_{shared,private,rw})
- ffilib open/ioctl -> os.open + fcntl.ioctl (pseudofiles_comprehensive)
- ffi libc/lib_inject calls -> ctypes (uprobes, proc_mtd_dynamic)
Requires the full CPython (ctypes/mmap/fcntl/socket), so bump
PENGUIN_TOOLS_VERSION to 0.0.6 (rehosting/penguin-tools#7).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The guest needs a full-featured Python. The micropython→CPython test migration (and real debugging use) needs ctypes (FFI for libc calls / ioctl), plus mmap, fcntl, socket, ssl, sqlite3 — none of which
python3Minimalbuilds.Switch
python.nixfrompython3Minimalto the fullpython3.Verified x86_64: lib-dynload now includes
_ctypes,fcntl,mmap,_socket,_ssl,_sqlite3(77 modules vs 63), the bundle's runtime link-closure check passes (libssl/libsqlite3/libffi/... staged into dylibs), and/igloo/utils/python3runs them.CI will confirm the full python3 cross-build across all arches.