Skip to content

Backfill now replays first approvals for GitHub PR triggers - #862

Open
promptless[bot] wants to merge 2 commits into
mainfrom
promptless/first-approval-backfill-2837
Open

Backfill now replays first approvals for GitHub PR triggers#862
promptless[bot] wants to merge 2 commits into
mainfrom
promptless/first-approval-backfill-2837

Conversation

@promptless

@promptless promptless Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Open in Promptless

Corrects the "Backfill suggestions" section of the triggers overview page and adds the August 2026 changelog entry. The page previously stated that a GitHub PR trigger configured only for first approval "returns no backfill results." Promptless/promptless#2837 makes that false: backfill now replays first approvals for GitHub PR triggers that activate only on first approval, including open pull requests whose first approval landed within the selected window even if they were opened before it. The correction states that GitLab merge request and Bitbucket PR triggers have no first-approval option, so this backfill behavior applies only to GitHub.

✅ Deferral resolved — ready for review. Promptless/promptless#2837 merged into main on 2026-08-15 at commit 922f2a1fe0bfd05d7dbfa6a676e1d35d7212f7e4. The three pre-merge follow-ups this change was held for are now complete:

  1. Confirmed #2837 has merged (SHA 922f2a1).
  2. Re-verified all four backfill claims against the merged commit (first-approval-only triggers are now backfillable; the preview lists open PRs whose first approval landed in the window; PRs opened before the window are included via the created:>=updated:>= widening; GitLab/Bitbucket have no first-approval option).
  3. Added three source citations pinned to the merged main SHA (runtime/replays/service.py, runtime/replays/git_sources/github.py, runtime/promptless_config/models.py).
  4. Folded in the previously-deferred August 2026 changelog entry (Improvements section) announcing the newly-shipped capability.

Trigger Events

…iggers

Corrects the Backfill suggestions section: a GitHub PR trigger set to
first_approval can now be backfilled (open PRs whose first approval
landed within the selected window). Reflects Promptless/promptless#2837.
GitLab MR and Bitbucket PR triggers still don't replay approvals.
@vercel

vercel Bot commented Aug 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
promptless-docs Ready Ready Preview Aug 15, 2026 12:43am

Request Review

PR Promptless/promptless#2837 (merged 922f2a1) makes backfill replay
first approvals for first-approval-only GitHub PR triggers. Add the
August 2026 changelog entry, tighten the triggers backfill paragraph
(GitLab/Bitbucket have no first-approval option), and refresh the
month subtitle.
Open the **Backfill suggestions** panel on a trigger row, choose a window of the **last 14 days**, **last 30 days**, or **last 90 days**, and select **Preview**. The preview lists the pull requests opened or merged in that window that the trigger matches, applying the same repository, topic, directory, and branch filters it uses for live events. When a trigger scopes repositories by GitHub topic (the **Trigger on repos with certain topics** option, covered in [Repository topics](/docs/connect/triggers/github-prs#repository-topics)), the preview lists pull requests only from repositories that carry a matching topic. Backfill covers up to 1,000 pull requests per repository in the window.

Backfill matches pull requests that were opened or merged but it doesn't replay historical approvals. A trigger that activates only on first approval returns no backfill results because approval matching applies only to live events going forward.
Backfill also replays first approvals for GitHub PR triggers that activate only on first approval: the preview includes open pull requests whose first approval landed within the selected window, even if they were opened before the window. GitLab merge request and Bitbucket PR triggers don't offer a first-approval option, so this backfill behavior applies only to GitHub.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

list_matching_pull_requests docstring: backfill now replays approval-shaped events for GitHub PR triggers with a first_approval-only clause, matching PRs whose first active approval landed in the window even if opened long before it.

Source: https://github.com/Promptless/promptless/blob/922f2a1fe0bfd05d7dbfa6a676e1d35d7212f7e4/runtime/replays/service.py#L993-L1002

Open the **Backfill suggestions** panel on a trigger row, choose a window of the **last 14 days**, **last 30 days**, or **last 90 days**, and select **Preview**. The preview lists the pull requests opened or merged in that window that the trigger matches, applying the same repository, topic, directory, and branch filters it uses for live events. When a trigger scopes repositories by GitHub topic (the **Trigger on repos with certain topics** option, covered in [Repository topics](/docs/connect/triggers/github-prs#repository-topics)), the preview lists pull requests only from repositories that carry a matching topic. Backfill covers up to 1,000 pull requests per repository in the window.

Backfill matches pull requests that were opened or merged but it doesn't replay historical approvals. A trigger that activates only on first approval returns no backfill results because approval matching applies only to live events going forward.
Backfill also replays first approvals for GitHub PR triggers that activate only on first approval: the preview includes open pull requests whose first approval landed within the selected window, even if they were opened before the window. GitLab merge request and Bitbucket PR triggers don't offer a first-approval option, so this backfill behavior applies only to GitHub.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

_recent_pull_request_search_queries: approval-mode search stays is:open but widens the date filter from created:>= to updated:>=, so PRs opened before the backfill window are included when their approval landed inside it.

Source: https://github.com/Promptless/promptless/blob/922f2a1fe0bfd05d7dbfa6a676e1d35d7212f7e4/runtime/replays/git_sources/github.py#L599-L628

Open the **Backfill suggestions** panel on a trigger row, choose a window of the **last 14 days**, **last 30 days**, or **last 90 days**, and select **Preview**. The preview lists the pull requests opened or merged in that window that the trigger matches, applying the same repository, topic, directory, and branch filters it uses for live events. When a trigger scopes repositories by GitHub topic (the **Trigger on repos with certain topics** option, covered in [Repository topics](/docs/connect/triggers/github-prs#repository-topics)), the preview lists pull requests only from repositories that carry a matching topic. Backfill covers up to 1,000 pull requests per repository in the window.

Backfill matches pull requests that were opened or merged but it doesn't replay historical approvals. A trigger that activates only on first approval returns no backfill results because approval matching applies only to live events going forward.
Backfill also replays first approvals for GitHub PR triggers that activate only on first approval: the preview includes open pull requests whose first approval landed within the selected window, even if they were opened before the window. GitLab merge request and Bitbucket PR triggers don't offer a first-approval option, so this backfill behavior applies only to GitHub.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

MergeRequestLifecycleEvent (GitLab MR / Bitbucket PR triggers) is Literal["opened", "merge"] and explicitly excludes first_approval, because the webhook lifecycle mapper never emits it for those providers -- confirms GitLab/Bitbucket first-approval triggers have no backfill analogue.

Source: https://github.com/Promptless/promptless/blob/922f2a1fe0bfd05d7dbfa6a676e1d35d7212f7e4/runtime/promptless_config/models.py#L64-L69

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