fix: api/cli/registry correctness, CI hardening & docs alignment sweep - #251
Merged
Conversation
… sweep) 25 fixes across the api/cli/registry/settings surface plus CI workflows, scripts, and docs — the third sweep batch. api: - up() self-heal runs the cross-instance port-collision precheck; restart() self-heals a missing override (#166) - apply() flips the registry backend kind before network staging so a transient fetch failure can't strand a binder:vm config on the redroid backend (#182) - adb doctor reports skip (not a phantom fail) for the GMS denylist on adopted devices (#201) - up()/restart() re-stage a hand-deleted .env, not just the override (#219) cli: - map FridaFetchError (#167) and --from-data OSError (#180) to the friendly error/exit-1 contract - guard --from-source/--android-version without --vm-kernel (#198) - validate the instance name before the --from-data copy (#199) - new `install-frida` verb the adopt hint already advertised (#205) - gate backend capability before the destructive-wipe confirm (#206) - normalize a signal-killed `shell` to POSIX 128+N exit codes (#217) registry/ports/settings: - fsync the registry write (temp + parent dir) so a crash can't empty instances.json (#203) - keep a poisoned instance's pinned host ports in the collision precheck (#216) - suppress the privileged-port advisory on the read-only cross-instance scan (#224) - reject non-positive timeout settings at startup (#196) CI/scripts/docs: - SHA-pin uv in rootfs-release.yml (#209); add 'opened' to the e2e trigger (#210); apt-get update before installs (#211) - changelog linter checks every verb in a chained example (#212); benchmark alert uses the host-normalized ratio (#188); loosen the lsposed-hook grep (#236) - refresh migration docs to api_version 8 (#213); fix architecture.md compose tokens (#214); correct the `wait` comments (#240); document IMAGE_SIZE_MB as MiB (#233) All covered by new tests; full gate green (ruff, mypy --strict src+tests, pytest 100% line+branch (1887 passed), shellcheck/shfmt, yamllint, actionlint, zizmor, codespell, deptry, uv lock, changelog lint). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P1YsNMpGizhSDDPCBu5cut
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.
Summary
Third sweep batch — 25 fixes across the api/cli/registry/settings surface plus CI workflows, scripts, and docs. Implemented by 9 file-disjoint parallel agents, each gate-verified, integrated cleanly (no cross-patch conflicts).
Fixes by area
api / lifecycle
up()self-heal runs the cross-instance port-collision precheck;restart()self-heals a missing override — neither boots with a colliding/zero-port mappingapply()flips the registry backend kind before network staging, so a transient fetch failure can't strand abinder: vmconfig on the redroid backenddoctorreportsskip(not a phantomfail) for the GMS denylist on adopted devicesup()/restart()re-stage a hand-deleted.env, not just the overridecli / error contract
FridaFetchErrorand create --from-data: a non-FileNotFoundError OSError from rmtree/copytree escapes cli.main() uncaught, breaking the error:/exit-1 contract #180--from-dataOSErrorto the friendly error/exit-1 contract--from-source/--android-versionwithout--vm-kernel--from-datacopybeetroot install_fridaverb, leaving adb-adopted devices no CLI path to install frida-server #205 newinstall-fridaverb theadopthint already advertised (Feature)shellto POSIX128+Nexit codesregistry / ports / settings
instances.jsonCI / scripts / docs
pipx install uv, the only workflow bypassing the SHA-pinned setup-uv path #209 SHA-pinuvinrootfs-release.yml(Security); e2e pull_request trigger omitsopened, so a PR opened already carrying thee2elabel never starts the e2e tiers #210 addopenedto the e2e trigger; Several CI install steps run apt-get install with no preceding apt-get update, so a stale runner index can 404 and fail the job #211apt-get updatebefore installs<…>form implied by the contract #236 loosen thelsposed-hookgrepapi_version8; architecture.md lists removed ADB_PORT/FRIDA_PORT tokens as compose-template env-file substitutions (ports moved to compose.override.yaml in v8) #214 fixarchitecture.mdcompose tokens; entrypoint.sh / flash-modules.sh / CLAUDE.md comments wrongly claim the trailingwaitkeeps the container alive (init is PID 1, not the entrypoint) #240 correct thewaitcomments; IMAGE_SIZE_MB knob/field is spelled MB but mke2fs treats the M suffix as MiB #233 documentIMAGE_SIZE_MBas MiBTesting
Full local gate green:
ruff,ruff format --check,mypy --strict(src+tests),pytest -p no:randomlyat 100% line+branch coverage (1887 passed, 6 docker-daemon skips),shellcheck/shfmt,yamllint,actionlint,zizmor,codespell,deptry,uv lock --check, changelog lint.🤖 Generated with Claude Code
https://claude.ai/code/session_01P1YsNMpGizhSDDPCBu5cut
Generated by Claude Code