Skip to content

feat(connectors): one line when gh is signed out on the agent's computer - #50549

Merged
Jinwoo-H merged 3 commits into
mainfrom
pencilfish-943
Nov 27, 2026
Merged

Jinwoo-H merged 3 commits into
mainfrom
pencilfish-943

Conversation

@Jinwoo-H

@Jinwoo-H Jinwoo-H commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

Agents act on GitHub through gh on the computer they run on; the GitHub connector only brings events in. When gh is signed out there, nothing said so. Now one quiet line says it, only while it is signed out. Signed in, everything looks exactly as before.

Files Added Deleted Net
Test 3 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​160 0 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​160
Prod 21 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​315 $\color{#cf222e}{\Huge{\mathbf{−}}}$​40 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​275

What Changed

  • One reader: bots.github.state now carries the answering host's gh sign-in (gh: 'signed-in' | 'signed-out' | 'missing') from the existing readGhSignIn (gh auth token), which is now cached for 15 s and shared with orca bot connectors. The host reads its own gh, so an agent on a paired computer reports that computer's gh to the desktop and the phone that show it.
  • Desktop: while gh is signed out, the GitHub connector page shows one line under its header ("gh is signed out on <this computer | host>. Run gh auth login there.", yellow dot, copy icon). The Connectors list row's status line reads "gh signed out on ", and the chat Connect card keeps its green Connected with the same line in its body.
  • Phone: the same line on the GitHub connector page and on the chat Connect card, naming the computer.
  • CLI: orca bot connectors prints "GitHub: gh, as your owner. gh is signed out on this computer. Ask your owner to run gh auth login here." Only the GitHub line changed.
  • The schema reads an unknown gh value as absent, so a newer host never breaks this build's GitHub page. An older host sends no gh, so nothing new shows.

Why

The owner should see the one thing that stops an agent working on GitHub: a missing gh login on its computer. The state hangs off the existing per-host GitHub read every GitHub surface already shares. That avoids a second poller or per-surface wiring.

Linked Issue

N/A (maintainer change)

Visual Proof

GitHub connector page, gh signed out:

(screenshot removed: contained real product data)

Chat Connect card, gh signed out (still Connected):

(screenshot removed: contained real product data)

Testing

  • Component fixtures (ghSignedOutList, ghSignedOutGitHubPage, githubConnectedGhSignedOut), with signed-in fixtures unchanged
  • bots-github.test.ts runs the real bots.github.state handler and cloud client, with gh and the cloud call faked. It checks that the state reaches the client through the phone's schema, that surfaces shown together share one gh read, that a later read sees gh auth login, and that an unknown value parses as absent.
  • pnpm check:changed passes

Performance

None that is noticeable: bots.github.state already runs only when a GitHub surface is shown (plus the existing 30 s follow while an install page is open). It now also runs one offline gh auth token, shared across callers for 15 s, so several surfaces shown together spawn gh at most once.

Risk

Level: Low. Display-only. The riskiest part is the extra field on the GitHub state answer: older phones and desktops drop it, and an unknown value reads as absent. Back out with a plain revert.

Review

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Cross-platform: uses the existing ghExecFileAsync wrapper. A missing gh (not installed) shows no new line in the UI; the CLI keeps its existing install hint.

…computer

The GitHub connector only brings events in; agents act on GitHub through the
computer's own gh login. bots.github.state now carries that host's gh sign-in
(read once per 15 s), so the GitHub page, Connect card, Connectors row, phone
and `orca bot connectors` say so only while gh is signed out.
@coderabbitai

coderabbitai Bot commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Walkthrough

The GitHub state response now includes local GitHub CLI sign-in state, with results cached for 15 seconds. Desktop and mobile connector surfaces display a signed-out notice with instructions to run gh auth login. Desktop connector rows can show a warning status that is hidden from the connector page status row. Connected offer cards display the notice in place of connected locations when the notice is available.

Merge Risk: Low · up to 483fd

The GitHub CLI signed-out notice can occasionally be stale or appear on the wrong card, or lack the computer name. These are small display issues and none breaks core connector flows.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: a single status line in the GitHub connector UI when gh is signed out on the agent's computer. The changeset adds that line on desktop and phone, plus the gh sign-in f…
Description check Passed The description covers the required template sections: ELI5, What Changed, Why, Visual Proof, Testing, Performance, Risk, and the AI disclosure and review sections, with the risk level stated as Low. …
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: a single status line in the GitHub connector UI when gh is signed out on the agent's computer. The changeset adds that line on desktop and phone, plus the gh sign-in field in bots.github.state and a CLI message. The title is specific and matches the primary change. It omits the CLI and state-plumbing parts, which the title does not need to cover.

Full details: Description check

Explanation

The description covers the required template sections: ELI5, What Changed, Why, Visual Proof, Testing, Performance, Risk, and the AI disclosure and review sections, with the risk level stated as Low. The Linked Issue section reads 'N/A (maintainer change)' rather than a 'Fixes #' link. The template says an issue should always exist for outside contributors, and this author is a maintainer, so the template's special case applies. The Testing checklist also leaves the manual-testing and test-anti-pattern boxes unchecked. Those items are not required for a pass. The Visual Proof section has before/after images, but it shows only the signed-out state, not a before view. The Testing section does not name the platforms tested.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 3

Review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 99c156ea-6cc5-4da2-a1d3-3c456f76fbb4
Commits

Reviewing files that changed from the base of the PR and between bf0997c and b20f538.

Files selected for processing: 19

  • mobile/src/bots/connectors/MobileBotGitHubPage.tsx
  • mobile/src/bots/connectors/MobileGhSignedOutLine.tsx
  • mobile/src/i18n/locales/en.json
  • mobile/src/session/native-chat/transcript/MobileNativeChatConnectorOfferRow.tsx
  • src/main/bots/bot-local-sign-ins.ts
  • src/main/runtime/rpc/methods/bots-github.test.ts
  • src/main/runtime/rpc/methods/bots-github.ts
  • src/renderer/src/components/bots/BotConnectorPageRow.tsx
  • src/renderer/src/components/bots/BotConnectorRow.tsx
  • src/renderer/src/components/bots/BotConnectorsPanel.fixture.tsx
  • src/renderer/src/components/bots/bot-connector-row-parts.tsx
  • src/renderer/src/components/bots/bot-connectors-host-fixture.tsx
  • src/renderer/src/components/bots/github/BotGitHubCard.tsx
  • src/renderer/src/components/bots/github/GhSignedOutLine.tsx
  • src/renderer/src/components/native-chat/NativeChatConnectorOfferCard.fixture.tsx
  • src/renderer/src/components/native-chat/NativeChatConnectorOfferCard.tsx
  • src/renderer/src/i18n/locales/en.json
  • src/shared/bots/bot-connectors-view.ts
  • src/shared/connector-bot-github-contract.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Comment thread src/main/bots/bot-local-sign-ins.ts Resolved
… and the CLI

A paired web window names its server instead of this computer, orca bot
connectors names a headless server, and the phone's card falls back to
"your computer" when the host has no name yet.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 3

Review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: f1d40ef6-c282-41f7-9f80-a18887dbfee2
Commits

Reviewing files that changed from the base of the PR and between b20f538 and 483fdc3.

Files selected for processing: 10

  • mobile/src/session/native-chat/transcript/MobileNativeChatConnectorOfferRow.tsx
  • mobile/src/session/native-chat/transcript/bot-cards/MobileBotCardHostProvider.tsx
  • src/main/runtime/rpc/methods/bots-connectors.test.ts
  • src/main/runtime/rpc/methods/bots-connectors.ts
  • src/renderer/src/components/bots/github/BotGitHubCard.tsx
  • src/renderer/src/components/bots/github/GhSignedOutLine.tsx
  • src/renderer/src/components/bots/github/gh-signed-out-host.test.tsx
  • src/renderer/src/components/bots/use-bot-host-label.ts
  • src/renderer/src/components/native-chat/NativeChatConnectorOfferCard.tsx
  • src/shared/bots/bot-connectors-view.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 3 remain after this review.

@Jinwoo-H
Jinwoo-H merged commit 8a6412d into main Nov 27, 2026
58 checks passed
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