* migration-test: port the historical-Dolt upgrade corpus to darwin/arm64
The harness was Linux/amd64-only, gated by an unconditional uname check.
Porting it turned out to need more than the linux-only STRICT_RELEASE_ASSETS
table: sourcing lib/versions.sh's associative arrays fails outright under
macOS's bundled bash 3.2 (no `declare -A` support), `realpath -e` and
`find -printf` are GNU-only, the release-binary version probe's sandboxed
PATH=/usr/bin:/bin has no `timeout` on macOS, and the v0.9.1 source build's
own scratch dir was never canonicalized against macOS's symlinked TMPDIR.
- lib/versions.sh: guard on bash >= 4 with an actionable message instead of
a cryptic mid-file parse error; add reviewed darwin|arm64 asset+checksum
entries for all 12 corpus versions (existence confirmed via `gh release
view`, checksums taken from each release's own checksums.txt — the same
provenance as the existing linux|amd64 rows, cross-checked byte-for-byte
against them).
- historical-dolt-upgrade-test.sh: accept linux/x86_64 or darwin/arm64
(still an explicit allowlist, not a generic passthrough); replace the two
`find -printf` uses with a portable per-entry describer (Linux keeps the
original find command unchanged) and a plain `-exec basename`.
- lib/binary.sh: add resolve_existing_path (realpath -e on Linux, plain
realpath elsewhere — verified to already require existence on macOS);
resolve `timeout` to an absolute path before entering the sandboxed probe
rather than widening its PATH; canonicalize the v0.9.1 build's scratch dir
immediately after mktemp; parameterize its GOOS/GOARCH/cache-path instead
of hardcoding linux/amd64.
Validated natively on darwin/arm64: syntax-checked under bash 5; the
existing legacy-bridge-test.sh smoke suite passes unchanged (including its
assertion that the sandboxed probe PATH stays exactly /usr/bin:/bin); real
end-to-end runs of run.sh (the actual CI entrypoint) pass for the embedded
Dolt lane (v1.1.2), the external server-Dolt lane against the pinned Dolt
runtime (v0.62.0 — production's current schema), and a classic-SQLite bridge
lane (v0.49.6). linux|amd64 behavior is unchanged (existing entries and
branches are untouched byte-for-byte; only new darwin-only branches added).
v0.9.1's own lane gets past every platform fix here and then hits an
unrelated, pre-existing bug: migrate-legacy-to-current.sh's bridge
comparison stringifies timestamps as local-time-with-offset on the old side
and UTC-Z on the candidate side, so it only happens to line up when the
runner's local timezone is UTC (true for CI, false here). Left unfixed as
out of scope for a platform-corpus change — noted for the reviewer.
Ref: ga-9sghx (Gas Town HQ)
* fix(ga-9sghx): address PR #6072 review feedback
bee-ghosttrack's review (CHANGES_REQUESTED) found resolve_existing_path's
non-Linux branch assumed BSD realpath, but Homebrew coreutils puts GNU
realpath on macOS PATH too — and GNU's flagless default silently accepts
a missing final path component, dropping the existence guarantee this
function promises callers. Add an explicit [ -e "$1" ] guard so it holds
regardless of which realpath resolves.
Also skip the v0.63.3 embedded-Dolt lane specifically on darwin/arm64:
that release's published darwin/arm64 binary was built without CGO and
can't open an embedded-Dolt store at all — an upstream release artifact
limitation, not fixable here. Skipping just that one version (with an
explicit, non-silent message) keeps ./run.sh from being permanently red
on a Mac; every other embedded-Dolt version is unaffected.
Verified: legacy-bridge-test.sh passes; --version v0.63.3 now exits via
the explicit skip instead of the CGO error; resolve_existing_path
unit-checked directly for both the existing-path and missing-path cases.
---------
Co-authored-by: Test <test@example.com>