Code review

Pre-review

Review a pushed branch privately before you open its pull request.

A pre-review runs the same review Abstraction gives a pull request, but on a branch that has no pull request yet. You see the findings first, fix what needs fixing, and open the pull request once the branch is in shape. Nothing is posted to GitHub while it's a pre-review.

Pre-review is rolling out workspace by workspace. If you don't see Review a branch on the PR Reviews page, it isn't enabled for your workspace yet.

Before you start

  • You need the admin or editor role in the workspace.
  • The repository has to be one the workspace tracks.
  • Push the branch first. The review reads the branch from GitHub, so commits that are only on your machine aren't reviewed.

Start a pre-review

In the web app

On the PR Reviews page, choose Review a branch. Pick the Repository (only asked when the workspace has more than one), the Branch to review, and optionally a Base to compare against. The base defaults to the repository's default branch. You can also type a branch name that isn't in the list yet. Choose Review to start.

The report opens straight away and shows progress as the review runs. If the branch's new code hasn't been analyzed yet, the review waits for that and starts on its own.

Your open pre-reviews are listed under Your branches, above the pull requests, labelled with the branch name.

From the CLI

Run abstr review inside a checkout to pre-review the branch you're on:

abstr review
abstr review --base develop

The CLI reads the current branch and the GitHub origin remote, warns you if the branch or your latest commits haven't been pushed, and follows the review until it finishes. It then lists the open findings. Press Ctrl-C to stop watching; the review keeps running.

FlagDescription
--base <branch>Branch to compare against (default: the repo default)
--no-waitStart the review and return immediately
--follow <id>Reattach to a review that's already running
--jsonPrint progress and findings as NDJSON events
-w, --workspaceWorkspace to use

Pass a pull request URL instead, abstr review https://github.com/org/repo/pull/42, to review a pull request the same way. The command exits non-zero unless the review completed.

To rule on a finding once you've dealt with it, pass its id to abstr review resolve, for example abstr review resolve 4211 --as fixed. On a pre-review nothing reaches GitHub. See abstr review resolve.

From a coding agent

Over MCP, request_pr_review with a repository and branch (and optionally base_branch) pre-reviews a branch that has no open pull request. By default the call waits for the review and returns its findings; pass wait=false to return at once and read the result later with get_pr_review. Calling request_pr_review again after pushing fixes re-runs the same review. If the branch already has an open pull request, its pull request is reviewed instead.

For issues the agent leaves unfixed, update_pr_review_issues marks them invalid, won't fix or a duplicate, with a reason, and the next run doesn't raise them again. Updates to a pre-review never reach GitHub.

Who can see it

A pre-review is visible only to the person who started it. Teammates don't see it in the list, can't open its report, and nothing appears on GitHub.

New commits

Pushing to the branch re-reviews it automatically. To change that for one branch, open its report and use the Review new commits menu. You can also rerun a pre-review from its report header at any time.

When you open the pull request

Once the branch is in shape, choose Open pull request in the report's header, give it a title and optionally a description, and Abstraction opens the pull request into the pre-review's base on GitHub as you. This needs your GitHub account connected. Opening the pull request on GitHub yourself works the same way.

When you open a pull request for the branch, the pre-review becomes that pull request's review report, and from then on it follows the usual pull request flow: your teammates can see it, and the pull request gets its own first review, posted to GitHub.

That first review starts fresh, and earlier pre-review findings aren't repeated as if they were new. The ones you dismissed or voted down are passed to the reviewer, so it doesn't raise them again. The report keeps the pre-review's runs and findings in a collapsed Pre-review section of its timeline.

A draft pull request takes over the pre-review without starting a review; the review runs when the pull request is marked ready. Pull requests opened from a fork don't take over a pre-review.

When the branch goes away

Deleting the branch closes its pre-review and stops any review still running.

Next steps

© Abstraction — documentation