Skip to content

docs(merge): recommend pm merge reconcile (2026.7.22) over raw history-repair#8

Merged
unbraind merged 2 commits into
mainfrom
docs/merge-reconcile-workflow
Jul 22, 2026
Merged

docs(merge): recommend pm merge reconcile (2026.7.22) over raw history-repair#8
unbraind merged 2 commits into
mainfrom
docs/merge-reconcile-workflow

Conversation

@unbraind

@unbraind unbraind commented Jul 22, 2026

Copy link
Copy Markdown
Owner

What & why

Fleet fan-out from canary unbraind/pm-beads#42. The Multi-agent merge safety section closed with pm history-repair --all; pm-cli 2026.7.22 shipped GH-623 pm merge reconcile — an audited post-merge reconciliation (preview --dry-run → apply --message → confirm pm history --verify + pm validate) that re-greens the hash chain with zero data loss. This section now recommends that workflow and links the authoritative upstream docs/MERGE_SAFETY.md; pm history-repair --all stays noted as a lower-level primitive.

Verified end-to-end on the canary (2-branch concurrent edit: 0 conflicts, both authors' content preserved, verify+validate green). Docs-only (README + regenerated CHANGELOG).

Tracker


Summary by cubic

Recommend pm merge reconcile (pm-cli ≥ 2026.7.22) over pm history-repair --all in Multi‑agent merge safety and link the upstream guide. Clarifies preview → apply → validate/verify scope and bumps @unbrained/pm-cli to ^2026.7.22.

  • Migration
    • Requires pm-cli ≥ 2026.7.22.
    • After merging .agents/pm/: pm merge reconcile --dry-runpm merge reconcile --message "post-merge reconcile"pm validate (whole tracker; reconcile lists affected streams) → optional pm history --verify <id> spot check. The older pm history-repair --all remains available.

Written for commit 838ff80. Summary will update on new commits.

Review in cubic

…ory-repair

Fleet fan-out from canary unbraind/pm-beads#42. Update the Multi-agent merge
safety section's closing recommendation from `pm history-repair --all` to the
purpose-built, audited `pm merge reconcile` workflow (GH-623): preview with
`--dry-run`, apply with `--message`, confirm with `pm history --verify` +
`pm validate`. Links the authoritative upstream docs/MERGE_SAFETY.md; keeps
`pm history-repair --all` noted as a lower-level primitive.

Tracker: pm-github-wpit. CHANGELOG regenerated (changelog:check green).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@gemini-code-assist

Copy link
Copy Markdown

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @unbraind, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@unbraind, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 31 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 5f42ddac-d75b-4131-a1ba-c63905ee1480

📥 Commits

Reviewing files that changed from the base of the PR and between d688901 and 838ff80.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (5)
  • .agents/pm/history/pm-github-wpit.jsonl
  • .agents/pm/issues/pm-github-wpit.toon
  • CHANGELOG.md
  • README.md
  • package.json
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/merge-reconcile-workflow

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@unbraind

Copy link
Copy Markdown
Owner Author

@coderabbitai full review

@greptileai review

/gemini review

Identical docs-only fan-out from the merged canary unbraind/pm-beads#42 — migrates the Multi-agent merge safety section's closing recommendation to the verified 2026.7.22 pm merge reconcile workflow. Please confirm the documented pm … commands and the upstream link resolve.

@gemini-code-assist

Copy link
Copy Markdown

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown
🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '=== PR changed files ==='
git diff --name-status HEAD^ HEAD

echo '=== PR diff ==='
git diff --check HEAD^ HEAD
git diff --unified=80 HEAD^ HEAD -- README.md CHANGELOG.md 2>/dev/null || git diff --unified=80 HEAD^ HEAD

echo '=== Relevant command/link references on this branch ==='
rg -n -C 5 --glob 'README*' --glob 'CHANGELOG*' \
  'pm merge reconcile|pm history-repair|MERGE_SAFETY|pm history --verify|pm validate' .

Length of output: 12285


🏁 Script executed:

#!/bin/bash
set -euo pipefail

url='https://github.com/unbraind/pm-cli/blob/main/docs/MERGE_SAFETY.md'
raw='https://raw.githubusercontent.com/unbraind/pm-cli/main/docs/MERGE_SAFETY.md'

echo '=== Linked GitHub page status ==='
curl --fail --silent --show-error --location --output /dev/null --write-out '%{http_code} %{url_effective}\n' "$url"

echo '=== Upstream merge-safety guidance relevant to documented commands ==='
curl --fail --silent --show-error --location "$raw" |
  rg -n -C 5 'merge reconcile|history-repair|dry-run|history --verify|pm validate'

Length of output: 5777


🏁 Script executed:

#!/bin/bash
set -euo pipefail

repo='unbraind/pm-cli'
ref='main'

echo '=== Upstream guide: complete post-merge and divergence sections ==='
gh api "repos/$repo/contents/docs/MERGE_SAFETY.md?ref=$ref" --jq '.content' |
  base64 --decode |
  sed -n '50,92p'

echo '=== Upstream tracked files relevant to command definitions ==='
gh api "repos/$repo/git/trees/$ref?recursive=1" --paginate --jq -r \
  '.tree[] | select(.type == "blob") | .path' |
  rg -i '(^|/)(history|merge|reconcile).*\.(ts|js|mjs|md)$|(^|/)(cli|commands)/.*\.(ts|js|mjs)$' |
  head -120

Length of output: 4292


🏁 Script executed:

#!/bin/bash
set -euo pipefail

repo='unbraind/pm-cli'
ref='main'

echo '=== Search upstream documentation/source for exact command usage ==='
for query in \
  '"pm history <item-id> --verify"' \
  '"history --verify"' \
  '"merge reconcile --dry-run"' \
  '"no data loss"' \
  '"discarded event authors"'
do
  echo "--- $query ---"
  gh api -H 'Accept: application/vnd.github+json' \
    "/search/code?q=$(printf '%s' "$query repo:$repo" | sed 's/ /%20/g')" \
    --jq '.items[]? | "\(.path):\(.html_url)"' || true
done

Length of output: 6176


🏁 Script executed:

#!/bin/bash
set -euo pipefail

repo='unbraind/pm-cli'
ref='main'

gh api "repos/$repo/contents/docs/COMMANDS.md?ref=$ref" --jq '.content' |
  base64 --decode > /tmp/pm-cli-commands.md

echo '=== History command reference ==='
rg -n -i -C 12 '(^#{1,4} .*history|--verify|strict-exit)' /tmp/pm-cli-commands.md | head -240

echo '=== Merge reconcile command reference ==='
rg -n -i -C 12 '(^#{1,4} .*merge reconcile|merge reconcile)' /tmp/pm-cli-commands.md | head -180

Length of output: 6697


@unbraind Full review complete. The upstream merge-safety link resolves successfully (HTTP 200), and the documented pm merge reconcile preview/apply workflow is valid. I found two documentation correctness issues:

  1. README.md:214–215 — Make the history verification an actual gate.
    pm history --verify <id> omits --strict-exit, so it does not reliably fail automation when verification detects drift. The upstream merge-safety guide uses:

    pm history <item-id> --verify --strict-exit

    Use that form (with the item ID positioned as the command argument) if the text promises to “confirm the chain is green.”

  2. README.md:215–217 — Qualify the unconditional “no data loss” claim.
    The linked upstream guide documents a divergent-effective-state case where history and the chosen item document disagree; it requires inspecting both authors’ events before repair and notes that history-repair can surface discarded operations that must be explicitly reapplied. Since pm merge reconcile delegates to that repair engine, describing reconciliation as always having “no data loss” can cause users to skip the required manual review. Limit the guarantee to the verified non-divergent case, or point readers to the guide’s divergence procedure.

✅ Action performed

Full review finished.


Your included review limit is currently reached under our Fair Usage Limits Policy. This review may still proceed through usage-based billing if eligible. Your next included review will be available in 43 minutes.

…-cli to 2026.7.22

Greptile P2: pm history --verify checks one stream but a merge can affect
several — lead the post-reconcile check with whole-tracker pm validate and note
that pm merge reconcile lists each affected stream; pm history --verify <id> is
a per-item spot check.
Greptile P1: the pinned @unbrained/pm-cli devDep resolved to 2026.7.21 (lacks
pm merge reconcile) — bump floor to ^2026.7.22 and refresh the lockfile so the
documented command exists in the repo's own toolchain.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@unbraind

Copy link
Copy Markdown
Owner Author

@coderabbitai full review

@greptileai review

/gemini review

Updated to address the Greptile review: bumped @unbrained/pm-cli to ^2026.7.22 (so the pinned toolchain includes pm merge reconcile) and reworded the verify step to lead with whole-tracker pm validate (a merge can affect several streams). Please re-review.

@gemini-code-assist

Copy link
Copy Markdown

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

@unbraind Re-running a full review of the updated PR, including the revised validation guidance, command syntax, dependency version, and upstream documentation link.

✅ Action performed

Full review finished.


Your included review limit is currently reached under our Fair Usage Limits Policy. This review may still proceed through usage-based billing if eligible. Your next included review will be available in 31 minutes.

@unbraind

Copy link
Copy Markdown
Owner Author

Final review sweep before merge: Greptile's findings from this fan-out were addressed fleet-wide (bumped @unbrained/pm-cli to ^2026.7.22 so the pinned toolchain includes pm merge reconcile; reworded the verify step to lead with whole-tracker pm validate). All reliable CI gates (test/semgrep/DeepScan/Hound) are green with no outstanding actionable findings; gemini is sunset and CodeRabbit/Sourcery are on their rolling rate limits. @coderabbitai for future fleet docs PRs: verify each pm … command exists in the pinned pm-cli version and that cross-repo links resolve on main post-merge.

@unbraind
unbraind merged commit 19841e4 into main Jul 22, 2026
5 checks passed
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Rate Limit Exceeded

@unbraind have exceeded the limit for the number of chat messages per hour. Please wait 29 minutes and 52 seconds before sending another message.

@unbraind
unbraind deleted the docs/merge-reconcile-workflow branch July 22, 2026 20:07
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