pr-view.sh (and issue-view/issue-edit) accept no --login or --host, so a seat cannot read a PR it can review #1224

Open
opened 2026-08-15 03:32:50 +00:00 by Ghost · 0 comments

pr-view.sh accepts neither --login nor -H/--host, so on any host where the default tea login is stale or absent it dies with user does not exist [uid: 0, name: ] and there is no flag that fixes it.

Measured

Usage today: pr-view.sh -n <pr_number> [-r owner/repo].

-r lets a caller aim at a repo outside its CWD, which is most of the point — but identity still falls through to whatever tea login matches the host, and when that login is stale the wrapper authenticates as nobody. The call fails with a message that reads like the reviewer does not exist, rather than like the wrapper could not resolve a login.

This blocked a reviewer seat mid-review: it was a valid collaborator with a working token, following a brief that told it to use pr-view.sh -n N -r owner/repo -H host -l seat, and both identity flags were silently ignored before the call failed on the stale default. Under gate 8 the seat correctly reported blocked — the wrapper failed, so it stopped. The verdict it had already produced sat undelivered until the read path was diagnosed.

Why this one is sharp

pr-review.sh does take -l/--login, -r/--repo and -H/--host, and with all three pinned the write, the identity read, and every read-back bind to the same login. So the write path is fine and the read path is not, which is the worst arrangement: a seat that can file a review cannot necessarily read the PR it is reviewing, and the failure surfaces as an identity error rather than a missing-flag error.

It also makes briefs wrong in a way that is hard to catch. A brief that pins -l on every wrapper looks careful and is silently ineffective on this one.

Requested change

  • accept -l/--login and -H/--host with the same semantics as pr-review.sh;
  • when a login cannot be resolved, fail with a message naming the resolution that was attempted, not with the API's user does not exist.

issue-view.sh and issue-edit.sh have the same missing-flag shape and should move with it.

`pr-view.sh` accepts neither `--login` nor `-H/--host`, so on any host where the default tea login is stale or absent it dies with `user does not exist [uid: 0, name: ]` and there is no flag that fixes it. ## Measured Usage today: `pr-view.sh -n <pr_number> [-r owner/repo]`. `-r` lets a caller aim at a repo outside its CWD, which is most of the point — but identity still falls through to whatever tea login matches the host, and when that login is stale the wrapper authenticates as nobody. The call fails with a message that reads like the *reviewer* does not exist, rather than like the wrapper could not resolve a login. This blocked a reviewer seat mid-review: it was a valid collaborator with a working token, following a brief that told it to use `pr-view.sh -n N -r owner/repo -H host -l seat`, and both identity flags were silently ignored before the call failed on the stale default. Under gate 8 the seat correctly reported `blocked` — the wrapper failed, so it stopped. The verdict it had already produced sat undelivered until the read path was diagnosed. ## Why this one is sharp `pr-review.sh` **does** take `-l/--login`, `-r/--repo` and `-H/--host`, and with all three pinned the write, the identity read, and every read-back bind to the same login. So the write path is fine and the read path is not, which is the worst arrangement: a seat that can file a review cannot necessarily read the PR it is reviewing, and the failure surfaces as an identity error rather than a missing-flag error. It also makes briefs wrong in a way that is hard to catch. A brief that pins `-l` on every wrapper looks careful and is silently ineffective on this one. ## Requested change - accept `-l/--login` and `-H/--host` with the same semantics as `pr-review.sh`; - when a login cannot be resolved, fail with a message naming the resolution that was attempted, not with the API's `user does not exist`. `issue-view.sh` and `issue-edit.sh` have the same missing-flag shape and should move with it.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mosaicstack/stack#1224