feat: maptool doctor CLI command for toolchain diagnostics - #528
Merged
Conversation
Replaces the static docs/map-tools-installation.md approach (PR #461) with a single diagnostic CLI command that detects all external tools, identifies known gotchas (wrong binary name, missing Python bindings, partial tippecanoe installs), and prints platform-specific install instructions. Commands: ocap-webserver maptool doctor — diagnose + install guide Key features: - Auto-detects OS and prints per-platform install steps - Probes tool versions via --version where available - Detects cross-tool issues (Python bindings missing, binary name mismatches) - Exits 0 only when all required tools (pmtiles, tippecanoe) are available - Three health levels: GREEN / YELLOW / RED
Contributor
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
Merging this branch will increase overall coverage
Coverage by fileChanged files (no unit tests)
Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code. Changed unit test files
|
fank
added a commit
that referenced
this pull request
Jul 24, 2026
* feat: add maptool tools and install subcommands Completes the original three-command proposal: ocap-webserver maptool tools — compact status table ocap-webserver maptool doctor — deep diagnostics (PR #528) ocap-webserver maptool install — platform-specific install guide maptool tools: - Quick status table sorted: required first, then alphabetical - Shows found/missing for all 10 tools with path and [required] tag - Exits 0 if all required tools present, 1 otherwise maptool install: - Prints platform-specific install instructions (auto-detects OS) - Reuses the install help infrastructure from doctor.go - Always exits 0 * chore: register tools/install subcommands in dispatch and update usage
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.
Instead of a static documentation file (previous approach in #461), provides a CLI command that both validates the map toolchain and gives users actionable install instructions.
Changes
New command:
ocap-webserver maptool doctorWhat the doctor checks
exec.LookPath— pmtiles, tippecanoe, tile-join, 5 GDAL C++ tools, 2 GDAL Python scripts--versionon each found tool)go-pmtilesinstalled instead ofpmtiles(wrong binary name — the pipeline needs exactlypmtiles)tippecanoefound buttile-joinmissing (partial install — they ship together)runtime.GOOS+/etc/os-release(Debian, Ubuntu, Fedora, RHEL, Alpine, NixOS, macOS, Windows)Health levels
Files
internal/maptoolcli/doctor.gointernal/maptoolcli/doctor_test.gointernal/maptoolcli/maptool.godoctorsubcommand, updated usagecmd/ocap-webserver/cli.goCloses #461 (supersedes the static docs approach)