Skip to content

fix(pr-details): handle Team/Mannequin reviewers + bump 0.1.4 - #10

Merged
IsraelAraujo70 merged 1 commit into
mainfrom
fix/pr-details-team-reviewer
Apr 30, 2026
Merged

IsraelAraujo70 merged 1 commit into
mainfrom
fix/pr-details-team-reviewer

Conversation

@IsraelAraujo70

Copy link
Copy Markdown
Owner

Summary

  • PR detail view broke with `network: error decoding response body` when a watched PR had a Team or Mannequin as a requested reviewer (very common in orgs). The GraphQL query only spread `... on User` on `requestedReviewer`, so for non-User reviewers the field came back as `{}` and serde failed to decode it as `GqlUser`.
  • Now the query selects `__typename` plus the right fields for User, Team and Mannequin, and the Rust side decodes `requestedReviewer` as a tagged enum with an `Unknown` fallback for future variants. Team is surfaced into `PrAuthor` using its `name` as the displayed login.
  • Bumps version to 0.1.4 to ship the fix through the auto-updater.

Test plan

  • `cargo check` passes locally
  • Open the previously broken PR (`GarantiaBR/atom-back-end#144`) — conversation tab loads, Team reviewer shows up in the Reviewers row
  • CI: `PR checks` workflow runs and labels `type/fix` + `area/backend` with a "patch bump" verdict

🤖 Generated with Claude Code

GraphQL query only spread `... on User` on requestedReviewer, so when a
PR had a Team or Mannequin requested as reviewer (common in orgs) the
field came back as `{}` and serde failed to decode it as `GqlUser`,
surfacing as "network: error decoding response body" in the UI.

Add fragments for Team and Mannequin, decode requestedReviewer as a
__typename-tagged enum (with an Unknown fallback for future variants),
and map Team's `name` into PrAuthor's `login` so the existing reviewer
list renders the team handle.

Bumps version to 0.1.4 to ship the fix.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

🔍 PR checks

Type: fix
Areas: area/backend

✅ Merging will trigger a release (patch bump)

fix: triggers a patch bump.

Auto-generated by pr-checks.yml. Edit the PR title to change the verdict.

@IsraelAraujo70
IsraelAraujo70 merged commit 0b1257a into main Apr 30, 2026
1 check passed
@IsraelAraujo70
IsraelAraujo70 deleted the fix/pr-details-team-reviewer branch April 30, 2026 16:56

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2ebbef3961

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src-tauri/src/commands.rs
Comment on lines 516 to 519
... on User { login avatarUrl }
... on Team { name avatarUrl }
... on Mannequin { login avatarUrl }
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Include Bot in requestedReviewer fragments

requestedReviewer can also be a Bot, but this query only requests fields for User, Team, and Mannequin. In that case the response contains only __typename, which is decoded as GqlReviewer::Unknown and then dropped by reviewer_to_author, so bot review requests disappear from the Reviewers row instead of being shown. This affects PRs where a GitHub App/bot is requested for review.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant