Make repo info, PR state, and current-PR lookups fallible #646

Closed
opened 2026-05-06 19:56:26 +00:00 by barrettruth · 0 comments
Owner

Parent: #634

Problem

Repo info, PR state, and current-PR resolution can parse empty/default data after command failure. Auth, network, or repo-resolution errors may become READ, UNKNOWN, empty merge methods, or no PR found, which then drives availability and action behavior incorrectly.

Scope

  • Audit backend repo_info, pr_state, and pr_for_branch_cmd paths.
  • Distinguish real absence from command/API failure.
  • Preserve failure details for availability and resolution callers without noisy picker behavior.
  • Add tests for failed lookup commands.

Non-goals

  • Do not change merge permission semantics.
  • Do not change branch/head matching rules.
  • Do not change GitLab project-ID resolution semantics except to report failures.
Parent: #634 ## Problem Repo info, PR state, and current-PR resolution can parse empty/default data after command failure. Auth, network, or repo-resolution errors may become `READ`, `UNKNOWN`, empty merge methods, or `no PR found`, which then drives availability and action behavior incorrectly. ## Scope - Audit backend `repo_info`, `pr_state`, and `pr_for_branch_cmd` paths. - Distinguish real absence from command/API failure. - Preserve failure details for availability and resolution callers without noisy picker behavior. - Add tests for failed lookup commands. ## Non-goals - Do not change merge permission semantics. - Do not change branch/head matching rules. - Do not change GitLab project-ID resolution semantics except to report failures.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
barrettruth/forge.nvim#646
No description provided.