Skip to content

fix: correct the backport runbook and default to non-fork pushes - #922

Merged
RiskeyL merged 2 commits into
mainfrom
fix/backport-runbook
Aug 1, 2026
Merged

fix: correct the backport runbook and default to non-fork pushes#922
RiskeyL merged 2 commits into
mainfrom
fix/backport-runbook

Conversation

@RiskeyL

@RiskeyL RiskeyL commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Three defects in the local backport path, each hit in practice during the #901/#903 backports, plus one verification gap:

  • The runbook's config example used accessToken; backport v12 only accepts githubToken, so following the doc failed at startup.
  • It instructed creating a new PAT; the existing gh login token already carries repo scope and org authorization, so the CLI examples now pass --githubToken "$(gh auth token)". Also clarified that the workflow's BACKPORT_TOKEN is a repository secret and unrelated to CLI auth.
  • .backportrc.json left fork at its default (true), so the CLI pushed to a nonexistent personal fork and died. "fork": false matches what the workflow already does.
  • New sections: resolve conflicts in the CLI's own clone at ~/.backport/repositories/<org>/<repo>, merge prerequisites before the backport PR is created, and verify propagation by content after merging — docs: document 16 env vars missing from environments.mdx #881 silently missed release/1.16.0 for two weeks.

Closes DC-143.

Copilot AI review requested due to automatic review settings July 31, 2026 15:11
@mintlify

mintlify Bot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
dify-core-product 🟢 Ready View Preview Jul 31, 2026, 3:12 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@dosubot dosubot Bot added size:M This PR changes 30-99 lines, ignoring generated files. documentation Improvements or additions to documentation labels Jul 31, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Updates the repository’s backport runbook and Backport CLI configuration to prevent common local backport failures (auth/config mismatches, pushing to a fork by default) and to improve operational guidance around prerequisites, conflict resolution, and post-merge verification.

Changes:

  • Revise .github/BACKPORT.md to update authentication guidance, add conflict-resolution workflow notes, and add a post-merge content verification step.
  • Set "fork": false in .backportrc.json so local backports default to pushing to the origin repo rather than a (possibly nonexistent) personal fork.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
.github/BACKPORT.md Updates the backport runbook with revised CLI auth examples, conflict-resolution guidance, and verification steps.
.backportrc.json Changes Backport CLI defaults to push to the origin repo ("fork": false).
Suppressed comments (2)

.github/BACKPORT.md:57

  • These CLI examples use --githubToken, but the Backport CLI flag is --github-token (kebab-case). As written, the token argument may be ignored and the command can fail authentication.
npx backport --pr-query "merged:>=2026-05-01 label:backport-pending" \
  --branch release/1.16.0 --branch release/1.15.0 --githubToken "$(gh auth token)"
# Or by path:
npx backport --path en/self-host/use-dify --branch release/1.15.0 --githubToken "$(gh auth token)"

.github/BACKPORT.md:63

  • This CLI example uses --githubToken, but the Backport CLI flag is --github-token (kebab-case).
npx backport --pr <source-pr-number> --branch release/<branch> --githubToken "$(gh auth token)"

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/BACKPORT.md
Comment thread .github/BACKPORT.md
Comment thread .github/BACKPORT.md Outdated
Copilot AI review requested due to automatic review settings July 31, 2026 15:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

@RiskeyL
RiskeyL merged commit 7adb27c into main Aug 1, 2026
2 checks passed
@RiskeyL
RiskeyL deleted the fix/backport-runbook branch August 1, 2026 03:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants