Repository navigation
Package the pipeline as navkit with a nav command - #3
Merged
Merged
Conversation
- src/navkit: installable package; pipeline stages are imported on demand so flashing and logging need only pyserial and esptool - nav flash: detect the chip, resolve the firmware release (manifest.json or file-name fallback), verify SHA-256, cache, flash with esptool - nav doctor, ports, firmware list/fetch, record, process, calibrate, sessions, log, wizard, where - workspace directory (~/navkit, --workspace, NAVKIT_HOME) replaces paths relative to the script - strict calibration gate by default when no terminal is attached - run_pipeline.py kept as a wrapper around the wizard - CI builds the package and tests a core-only install; release workflow publishes wheel and sdist on a tag, PyPI behind a repository variable
The session summary contains a micro sign, which the default Windows code page cannot encode; the Windows test legs caught it. The CLI also switches its console streams to UTF-8.
Merged
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.
Step 3 of the plan. Stacked on #2: merge that first, then retarget this to
main.What changes
navkit, that provides thenavcommand. It no longer has to run from a checkout.nav flashdetects the chip, finds the matching image in the firmware repo's GitHub Releases, verifies its SHA-256, caches it and flashes it with esptool.--fileflashes a local build.nav doctorchecks Python, pyserial/esptool, serial-port permissions, drivers and the workspace.nav record,process,calibrate,sessions,log,wizard,where,ports,firmware list|fetchreplace the numbered menu actions. The wizard is still there.calibration_params.jsonlive in a workspace:~/navkitby default, or--workspace/NAVKIT_HOME.pip install navkit) needs only pyserial, esptool and platformdirs.navkit[pipeline]adds pandas, numpy, scipy and matplotlib; the stages are imported on demand.run_pipeline.pystill works and uses the checkout as its workspace.Behaviour changes to be aware of
pipeline/tosrc/navkit/;session_trimmer.py→trimmer.py.data/in a checkout are not moved. Usepython run_pipeline.py, ornav --workspace ., to keep working on them.Testing
nav processruns on synthetic sessions andnav flashwith the board and GitHub stubbed.nav doctorruns and no heavy library is imported. CI repeats this.nav firmware listran against the real GitHub API (it correctly reports no releases yet).nav flash, chip detection andnav recordhave only run against stubs. Chip detection in particular (flash.detect_chip) uses esptool internals I could not exercise.Release
release.ymlpublishes wheel + sdist to a GitHub Release when av*tag matching the package version is pushed. PyPI publishing is off until the repository variablePYPI_PUBLISH=trueis set and the workflow is registered as a trusted publisher fornavkiton pypi.org (the name was free when I checked).Generated by Claude Code