Skip to content

fix(guided-review): load the review list when glab is not installed - #153

Merged
sleeyax merged 1 commit into
mainfrom
fix/guided-review-without-glab
Oct 14, 2026
Merged

sleeyax merged 1 commit into
mainfrom
fix/guided-review-without-glab

Conversation

@sleeyax

@sleeyax sleeyax commented Oct 14, 2026

Copy link
Copy Markdown
Owner

Summary

A reviewer who had gh but not glab could not load Guided Review's start screen.
To list GitLab hosts, the plugin runs glab auth status --all.
When glab was missing, the "Could not run glab" error escaped the GitLab listing and failed the whole list, GitHub's PRs included.
They worked around it by setting the glab path to /usr/bin/true, which prints nothing and so lists no GitLab hosts.

  • CliNotFoundError: a forge CLI that is not found (ENOENT) now throws this subclass of ForgeError, with the same message as before.
  • GitLab listing: reads CliNotFoundError as no GitLab hosts and returns an empty list.
  • Unchanged: a glab that is there but fails, cannot be executed (EACCES) or times out still fails the listing. Pasting a GitLab MR URL without glab still says glab could not run and points at the setting.

Evidence

A new test in server/forge/gitlab.test.ts replays a glab that cannot be found. It failed with the old code's ForgeError and passes now.
pnpm test passes (467 tests), tsc --noEmit is clean, and paseo plugin reload guided-review loads the plugin.

Merge Danger

Door: two-way

One catch in the GitLab listing; reverting brings back the failure.

Blast Radius: low

If glab is missing because the glab path in the settings is wrong, the start screen now shows no GitLab hosts without saying why.
Starting a review from a GitLab MR URL still shows the error.

The GitLab listing asks `glab auth status --all` for its hosts, and a glab that could not be found threw out of it, so the whole review list failed, GitHub's PRs included.
A CLI that is not found now throws a `CliNotFoundError`, which the GitLab listing reads as no GitLab hosts.
A glab that is there but fails, cannot be executed or times out still fails the listing as before.
Reported by a GitHub-only reviewer, who worked around it by setting the glab path to `/usr/bin/true`.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sleeyax
sleeyax merged commit 0ce14f3 into main Oct 14, 2026
1 check passed
@github-actions github-actions Bot mentioned this pull request Oct 12, 2026
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