Skip to content

How overpressure fits together

TL;DR. overpressure is one Python package, the engine, and an app around it. The app (a web front end in a Tauri shell) carries its own Python with the engine inside and talks to it in JSON lines; its executable is the command line too. Each headset is its own repository, downloaded into devices/, that declares its commands, steps and installer plan; overpressure draws the pages and runs them. overpressure's own files and the owner's data live apart, so an update or an uninstall never reaches the owner's backups.

The parts

Part What it is
The app app/: a web front end (Svelte 5, TypeScript, Vite; Inter bundled) in a Tauri 2 shell, with overpressure and its Python inside (the app, for owners)
The engine overpressure/: the Python package, Python 3.12+ on the standard library with pinned packages where they spare the owner an outside tool (Python packages); it runs on Windows, Linux and macOS
The command line the app's executable started with words, or uv run overpressure in a checkout (the command line)
The headsets one repository each, in devices/<codename>/ (headsets in devices/), on the headset interface
The headset runtime the part of a headset's Linux every headset shares (runtime)
The build container where the builds' Linux side runs (Linux-root steps)

A headset declares; overpressure draws and runs. A headset has no UI code: the app builds every page from what the headset declares, its steps, its plan's stages and tasks, the questions it asks, the notes it writes and its finished page (what a headset may use).

The app and its engine

The app's Rust core starts the engine as the app's server and passes lines both ways; the web view has no shell or file access of its own. Its engine is the one it was installed with, else the python on PATH in the checkout it was built in; OVERPRESSURE_PYTHON and OVERPRESSURE_ROOT name another Python and overpressure folder.

The installed app runs for real, the demo only with OVERPRESSURE_APP_DEMO=1; a development build (pnpm tauri dev, the checkout's engine) runs the demo unless OVERPRESSURE_APP_REAL=1, so that a developer's own headset is touched only on request. The window says Demo ยท nothing touches a headset while the demo runs.

Closing the window while a run or a job is under way asks first; Stop and close ends the engine's stdin, which stops the run (a write under way finishes first).

The server runs the installer as a child (overpressure install --json), reads its events line by line and answers its asks on the child's stdin, so whatever the app does a terminal does too, and the engine alone decides when it is safe to stop (overpressure/engines.py).

The bundled engine

The app ships its engine as its resources, src-tauri/engine/, filled by scripts/bundle-app.py (building it):

Folder or file What
python/ uv's managed Python 3.12 (a python-build-standalone build), from the uv bundle-app.py pins (its version and each system's SHA-256), with uv.lock's packages, exported with their hashes and installed with every hash required; without the standard library's tests, IDLE and Tk, which the engine does not need
root/ what git tracks under overpressure/, devices/__init__.py, pyproject.toml (the version), .env.example and the licences, compiled to bytecode
bin/overpressure.exe Windows: the command line's console twin (starting it)
bundle.json the Python's and the packages' versions, overpressure's commit, the files and bytes

The Python is relocatable, so the app runs it where it was installed, without the computer's own Python: no user site-packages, no PYTHONPATH or PYTHONHOME. On Windows: Python 3.12.15 with brotli, pyusb, libusb-package and truststore, 59 MB in 2,300 files, overpressure 3 MB; the installer is about 16 MB.

Two roots

overpressure's own files are overpressure.CODE; the owner's data (settings.json, backup/, assets/, cache/, out/, the headsets in devices/) is overpressure.REPO, the data root. In a checkout both are that folder.

The app's engine is marked as such (.bundled in its root) and keeps its data where an update or an uninstall never reaches (the data folder): on Windows %LOCALAPPDATA%\overpressure-data (the per-user installer installs into %LOCALAPPDATA%\overpressure, and its delete app data removes the app identifier's folder), on macOS ~/Library/Application Support/overpressure, elsewhere $XDG_DATA_HOME/overpressure (~/.local/share/overpressure). OVERPRESSURE_HOME names another data root anywhere.

  • Children run in the data root with CODE on PYTHONPATH.
  • devices imports from both roots, the data root's first.
  • The build container sees /work as a checkout: the data root, overpressure's own files mounted read-only into it.
  • The headsets are downloaded into the data root and found only there: they name their files relative to it. Output goes to the data root's out/, downloads to cache/.

An earlier overpressure

Before the app, overpressure came as a zip unpacked into a folder of its own, its data inside it: the owner's settings (settings.json), what overpressure recorded about the headset (out/records.json; an older folder's .env, migrated on the way), the headset's backup (backup/, the way back to its own system), the installer's records (out/install/, which say what the headset runs), the headsets downloaded into devices/, and the files a headset's way back also needs (Headset.backup_set: the PICO 4's SSH key for overpressure's recovery).

On its first start a fresh data root starts with its first setup, right after the disclaimer and before the headsets. It asks after the earlier overpressure, offering the one found in Downloads, on the desktop or in Documents (or a folder in one of them) or in the home folder, or the one the owner chooses. The search skips hidden folders and looks at one file per folder, well under a second in a full home folder, and runs beside the server's other requests.

Bringing it over (overpressure/carryover.py): the backup moves (a rename on the same disk) and the rest is copied, replacing nothing the data root has, and the earlier folder gets a MOVED.txt that says where its backup went. The settings and records merge key by key, and where the earlier folder's programs came from (a tool of its own in its cache/) stays behind: the fetched tools count here. Start fresh is remembered (out/carried-over.json), and a checkout is never asked. overpressure carry-over [FOLDER] does the same from a terminal.

Versions

overpressure --version says which version runs, in both spellings and with its commit: overpressure 2026.12.0 beta 3 (2026.12.0b3, commit 0123abcd4567); a preview with its commit's time (2026.12.0 preview from 3 December 2026 (4d8f977), 2026.12.0.dev202612031154). The app's engine carries the commit (overpressure/version.py); a checkout asks git. Between releases main carries the next one's development version (2026.12.0.dev0), so a preview is never taken for the release before it (versions).

The modules

Module Role
overpressure/catalogue.py the headsets there are and their repositories; their releases on GitHub, a channel's or a version's, downloaded into devices/<codename>/ against the checksum and headset.json (headset list\|releases\|add)
overpressure/api/ The headset interface by major version (v2): the only way a headset imports overpressure; a later major keeps the old one's modules as adapters
overpressure/headset.py SUPPORTED, API and RETIRED, the headset interface's versions; headset.json read and checked; Headset (Info, commands(), steps(), dependencies(), usb_modes(), ram_boot(), install_plan(), workflows(), plan(), workflow_problem(), after_install(), finished_page(), backup_set(), adopt_backup(), settle_files(), touches()), Command, Step, Param, Workflow, BackupSet, AfterInstall, Action, the registry
overpressure/install.py the install engine: Stage, Task (with its Parts), Ask, the Context a task gets, the state, the lock, the events, install, upgrade and restore (the installer's engine)
overpressure/roles.py the building blocks of a headset's workflows, which its plan derives from: running its steps, the computer check, finding it in its maker's system, the consent, Wi-Fi, the owner's SSH key and the Wi-Fi profile, the recovery's flash and login (with the done checks a run that starts over needs), the EDL backup, the installed system's checks
overpressure/recovery.py the PC's side of a headset's own systems (Recovery, by a Profile and hooks): SSH, the waits, readback, the install, the build on the headset with this computer's downloads, the boot mode, the way back's wipe; Modes, the moves between fastboot, the maker's system and our own; InRun, the replug waits in a task
overpressure/acceptance.py the acceptance runner's scaffolding (AcceptanceRunner, which a headset's runner derives from with its checks): the preflight on the maker's system, and flash-run: the stock boot image pinned from the backup, the journalled flash of the run's test image, the login with the run's proof, read-only storage and readback, the diagnostics, the way back with stock boot restored; evidence and result.json in a new folder
overpressure/edl.py a Qualcomm Android headset's adb and EDL steps (QualcommHeadset): into EDL mode, edl-ng sessions, the device identified before any write, a stale session freed, the reset into the maker's system and the wait for it
overpressure/devicecli.py the device command line (DeviceCommands, which a headset's extends with its own words): the identity's probe, the unlock state, the backup over EDL, a bootloader partition written and read back, the whole backup back
overpressure/devcli.py the development loop's command line (DevCommands): the recovery image, the flash, the login, recovery and normal, the install, the restore, SSH
overpressure/look.py a look at a headset on USB without changing it (Look, which a headset's look derives from): EDL, the bootloader, the maker's system, our own system over SSH
overpressure/disclaimer.py, power.py, awake.py the disclaimer and the gate before a command that touches the headset (--accept-disclaimer, OVERPRESSURE_ACCEPT_DISCLAIMER); this computer's power: a battery below 30 % refuses those commands (Windows, Linux and macOS readers); the wake lock those commands hold to their end (before anything touches the headset)
overpressure/elevated.py administrator rights (an elevated token, root outside a container; not on GitHub Actions) refuse every command and the app's engine
overpressure/runner.py the process a step is on this host (a Linux-root step's in the build container), its display, running and stopping it
overpressure/__main__.py the command line
overpressure/serve.py the engine as a server for the app (the app's server): its requests, the settings, the disclaimer, runs and jobs (downloads, the backup, the logs, steps) with their events, the demo's fakes
overpressure/engines.py the app's child processes: the install engine (ChildEngine), a backup's export, import or check and the logs (BackupJob), and the demo's fakes (DemoEngine, DemoBackupJob)
overpressure/steps.py Advanced mode's model: the steps, their values and command lines, a Linux-root step's paths, a step's program and the demo's, the demo's checks
overpressure/appupdate.py The app's own updates: the newest release on its channel that carries the app (the app's updates)
overpressure/carryover.py A newer overpressure's folder takes the owner's data from the one beside it (an earlier overpressure)
overpressure/lp.py super's logical partitions: the metadata Android's dynamic partitions use
overpressure/progress.py The progress lines a child program prints, which the installer and the app show as bars
overpressure/version.py This overpressure's version in the tags' spelling, its channel and commit (--version)
overpressure/localconfig.py each headset's settings with its own key prefix, in layers: defaults, the records (out/records.json), the owner's (settings.json), a developer's .env and the environment; the one-time migration of an earlier .env; DeviceSettings, what every Qualcomm Android headset names (settings)
overpressure/fastboot.py flashing an image sparse above a size, raw below; a restart into the bootloader that returns once its new session is listed; the RAM boot: fastboot boot with the headset's checks, never a write
overpressure/doctor.py the dependency checks: the host's, the build container's, then the headset's (Headset.dependencies()) from the shared ones (settings, EDL backup and tools, adb and fastboot, Windows' USB link, Linux's USB access) (dependencies)
overpressure/usbaccess.py the USB access: what the installed udev rules grant for each USB mode on Linux, the fix per distribution, a connected device's access; on Windows the installed drivers and a connected device without one
overpressure/tools.py the pinned host tools in cache/tools
overpressure/web.py every download over HTTP(S): TLS verified by the system's own verifier (truststore), a short outage tried again, a failure that says why (downloads)
overpressure/linux.py the build container: its pinned image (overpressure/builder), one named build at a time, stopping it, the aarch64 handler, ownership
overpressure/recovery_ramdisk.py a recovery: an Alpine ramdisk in the stock Android boot image, from a headset's Spec
overpressure/runtime/, contract.py the headset runtime (runtime): the recovery's init, PID 1, services, USB gadget, storage policy, recovery deadline and library, under a headset's recovery overlay; the paths, files and words the PC reads and writes on the headset
overpressure/ota.py stock boot images and partitions from a vendor OTA (block OTAs and payload.bin), a member's parts over eight connections at once and resumed after an interruption, checked against the zip, brotli by the package or the command; a pinned file out of a remote zip, checked by its hash
overpressure/android.py, qualcomm.py adb and fastboot, fail-closed, the wait for Android's boot, a partition's size from getvar all; the SoC ID, EDL devices counted through pyusb (PowerShell, ioreg or sysfs without it), EDL (edl-ng, bkerler/edl), partition maps, a full backup (an unfinished one of the same headset goes on from where it stopped), a write verified by readback, and a whole backup written back LUN by LUN, each write read back
overpressure/backup.py verified backups and a partition's image in them; a headset's several backups (kept, use, delete); the backup archive (backup export, import and compact, backups)
overpressure/support.py the logs for a bug report (support-bundle): the installer's records and the headset's own files in one zip, this computer's identifiers masked
overpressure/holes.py a file's zero runs handed back to the file system (sparse files on NTFS, ext4, APFS), its content unchanged
overpressure/process.py, ssh.py programs and bounded waits; SSH with the project's key, the keys an image enrolls
overpressure/evidence.py, storage.py a run that records every step and command in its results folder, bounded waits and HTTP fetches; the read-only storage policy a headset's Linux stages enforce
bootimg, avb, sparse, payload, cpio, compress, alpine, apksign, kernelinfo, elfdeps, windows_ncm the formats and helpers Android-based headsets share (bootimg also edits a boot image's ramdisk and command line)
overpressure/assets.py a headset's assets out of its stock folder: the folder checked against its manifest, files out of its ext4 and FAT images, the assets manifest
overpressure/ext4.py, fat.py read-only readers of stock file system images: ext4 (32- and 64-bit, extents, block maps, holes, links) and FAT12/16/32 with long names; python3 -m overpressure.ext4 cat IMAGE PATH for the Linux build scripts
scripts/stock-lib.sh for a headset's Linux build scripts: a file out of a stock ext4 image
overpressure/kernelpin.py, kernelimage.py a headset on Valve's kernel: its pinned release of overpressure/linux (download, hashes, the build in its image, the contracts with the kernel's names), and a boot image with that kernel (the stock header's, command line rewritten by key, archives appended, checked)
overpressure/pacman.py, prefetch.py pacman's repositories on any host (Valve's databases, what a package depends on, pacman.conf, packages.lock), and a headset's downloads into a cache before the install writes it, each checked by its pin
overpressure/build/ a headset's builds, run with its folder (the build on the headset, kernel build): the userspace (build-userspace.sh, its flavour's part in flavours/KEY.sh, its prefix and hooks in the headset's userspace/build.sh and userspace/flavours/KEY.sh), the system's file system on super (build-system-image.sh), the build on the headset (build-on-headset.sh, a hook for what it runs beside), the kernel by the headset's kernel.json (build-kernel.sh, on the reproducible core build-kernel-tree.sh, which an older headset's kernel/build-tree.sh sources itself) and the kernel step, the weekly upgrade check on Valve's newest packages (upgrade-check.sh, upstream.py); the downloads' retries (fetch.sh), the base root's databases and the package lock
overpressure/preflight-device.sh, windows-share-internet.ps1 the acceptance runner's preflight under the maker's system (a headset's hook adds its checks), and a Windows PC's internet shared with a headset over its USB link (ICS at the link's host address)