Skip to content

fix: compare JSON nesting, list null array, hold-remove false success + 1.0.10 release prep#27

Merged
postgresql007 merged 1 commit into
mainfrom
fix/three-inconvenience-bugs
Jul 15, 2026
Merged

fix: compare JSON nesting, list null array, hold-remove false success + 1.0.10 release prep#27
postgresql007 merged 1 commit into
mainfrom
fix/three-inconvenience-bugs

Conversation

@postgresql007

Copy link
Copy Markdown
Contributor

Three verified day-to-day inconveniences, each fixed with a regression test, plus the 1.0.10 release prep. (The #26 recovery drill sandbox fix is already on main and rides in this release.)

  1. backup compare -o json double-nested its payload at .result.result.* — fields now inline at .result.* like every other command.
  2. Empty list emitted "backups": null — now [], so jq '.result.backups[]' handles the empty case.
  3. hold remove --yes false success: releasing a nonexistent hold printed ✓ Hold released (exit 0) while the real hold kept blocking retention. Now notfound.hold (exit 6) with a hold list pointer; real releases unchanged. The old test encoding the exit-0 contract was rewritten.

Verified: unit + full-tree suite green (go vet clean); E2E against a live repo — fake-ID release refuses (6) and leaves the real hold untouched, real release still works; compare/list JSON shapes checked live.

Also verified but deferred (backlog): YAML renderer prints big integers in e-notation; -o csv never produces the tabular shape its docs promise.

- backup compare -o json double-nested its payload under
  .result.result.* — the ComparisonResult fields now inline at
  .result.* like every sibling command.
- list on an empty deployment emitted "backups": null, breaking every
  consumer iterating .result.backups[]; it now emits [].
- hold remove --yes printed "✓ Hold released" (exit 0) for holds that
  never existed — a false success on the legal-hold path: a typo'd
  backup ID confirmed a release while the real hold silently kept
  blocking retention. Removal of a nonexistent hold now fails with
  notfound.hold (exit 6) and points at `hold list`; the storage layer
  stays idempotent, the operator-facing verb validates.

Release prep: CHANGELOG 1.0.10 (these three + the #26 sandbox
pg_verifybackup -n fix already on main) and doc version examples
bumped. All fixes carry regression tests; the test that encoded the
old absent-hold exit-0 contract now asserts the new one.
@postgresql007
postgresql007 merged commit 6f6d7d5 into main Jul 15, 2026
6 checks passed
@postgresql007
postgresql007 deleted the fix/three-inconvenience-bugs branch July 15, 2026 18:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant