• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lsm / neokai / 25297572842
82%

Build:
DEFAULT BRANCH: dev
Ran 04 May 2026 02:07AM UTC
Jobs 29
Files 531
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 May 2026 02:06AM UTC coverage: 71.299% (-0.3%) from 71.587%
25297572842

push

github

web-flow
Add Google Gemini OAuth provider with account rotation (#1775)

* Add Google Gemini OAuth provider with account rotation backend

Implements a complete Gemini OAuth provider that authenticates via
Google Pro subscription credentials, rotates across multiple accounts
per session, and auto-failovers when an account is exhausted.

Core modules:
- OAuth client with PKCE headless auth flow (token exchange, refresh, validation)
- Format converter for Anthropic Messages API ↔ Gemini Code Assist translation
- Account rotation with session affinity, LRU selection, and exhaustion detection
- Bridge server using Bun.serve() for synchronous Provider interface compatibility
- Credential storage in ~/.neokai/gemini-oauth-accounts.json

OAuth credentials are loaded from GOOGLE_GEMINI_CLIENT_ID and
GOOGLE_GEMINI_CLIENT_SECRET env vars (defaults match Gemini CLI).

All 70 new unit tests pass, plus all 681 existing provider tests.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* Fix test env vars and validate refresh token in OAuth flow

P1: Add beforeEach/afterEach to set GOOGLE_GEMINI_CLIENT_ID/SECRET
    env vars in gemini-oauth-client.test.ts and gemini-provider.test.ts
    so tests pass without real credentials.

P2: Add explicit throw in completeOAuthFlow when Google OAuth returns
    no refresh_token, preventing silent account creation failures.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

* Fix SSE buffer handling, tool_use stop reason, and tool_result name mapping

P1: Move dataBuffer outside the SSE read loop in bridge-server.ts so
    events whose blank-line terminator arrives in a later TCP chunk are
    not dropped. Also fix the same issue in collectGeminiResponse.

P1: Emit tool_use stop reason (instead of end_turn) when a Gemini
    candidate contains functionCall parts, so Anthropic-compatible
    clients correctly trigger tool execution loops.

P2: Build a tool_use_id → function name map from prior tool_use blocks
    so tool_re... (continued)

7842 of 10820 branches covered (72.48%)

Branch coverage included in aggregate %.

780 of 1491 new or added lines in 8 files covered. (52.31%)

63103 of 88683 relevant lines covered (71.16%)

252.17 hits per line

Uncovered Changes

Lines Coverage ∆ File
522
1.88
packages/daemon/src/lib/providers/gemini/bridge-server.ts
123
62.61
packages/daemon/src/lib/providers/gemini/gemini-provider.ts
34
84.04
packages/daemon/src/lib/providers/gemini/account-rotation.ts
32
85.05
packages/daemon/src/lib/providers/gemini/oauth-client.ts
Jobs
ID Job ID Ran Files Coverage
1 daemon-0-shared - 25297572842.1 04 May 2026 02:07AM UTC 28
84.09
GitHub Action Run
2 daemon-online-coordinator - 25297572842.2 04 May 2026 02:07AM UTC 304
6.52
GitHub Action Run
3 daemon-online-rpc-2 - 25297572842.3 04 May 2026 02:08AM UTC 304
20.08
GitHub Action Run
4 daemon-online-rewind-1 - 25297572842.4 04 May 2026 02:08AM UTC 304
19.12
GitHub Action Run
5 daemon-online-components - 25297572842.5 04 May 2026 02:07AM UTC 304
15.23
GitHub Action Run
6 daemon-5-space-agent - 25297572842.6 04 May 2026 02:07AM UTC 157
28.3
GitHub Action Run
7 daemon-online-lifecycle - 25297572842.7 04 May 2026 02:08AM UTC 304
19.34
GitHub Action Run
8 daemon-5-space-runtime - 25297572842.8 04 May 2026 02:07AM UTC 145
38.96
GitHub Action Run
9 daemon-online-features-3 - 25297572842.9 04 May 2026 02:07AM UTC 304
14.06
GitHub Action Run
10 daemon-4-space-storage - 25297572842.10 04 May 2026 02:08AM UTC 126
50.82
GitHub Action Run
11 daemon-online-features-1 - 25297572842.11 04 May 2026 02:08AM UTC 304
19.6
GitHub Action Run
12 daemon-online-mcp - 25297572842.12 04 May 2026 02:07AM UTC 304
15.62
GitHub Action Run
13 daemon-online-rpc-1 - 25297572842.13 04 May 2026 02:08AM UTC 304
16.51
GitHub Action Run
14 daemon-online-rpc-4 - 25297572842.14 04 May 2026 02:08AM UTC 304
19.83
GitHub Action Run
15 daemon-online-git - 25297572842.15 04 May 2026 02:08AM UTC 304
20.07
GitHub Action Run
16 daemon-online-space-2 - 25297572842.16 04 May 2026 02:09AM UTC 304
26.86
GitHub Action Run
17 daemon-online-space-1 - 25297572842.17 04 May 2026 02:08AM UTC 304
26.64
GitHub Action Run
18 daemon-2-handlers - 25297572842.18 04 May 2026 02:07AM UTC 174
45.63
GitHub Action Run
19 daemon-online-convo - 25297572842.19 04 May 2026 02:08AM UTC 304
18.85
GitHub Action Run
20 daemon-online-sdk - 25297572842.20 04 May 2026 02:08AM UTC 304
18.86
GitHub Action Run
21 daemon-1-core - 25297572842.21 04 May 2026 02:08AM UTC 308
32.57
GitHub Action Run
22 daemon-5-space-other - 25297572842.22 04 May 2026 02:07AM UTC 122
29.79
GitHub Action Run
23 web - 25297572842.23 04 May 2026 02:08AM UTC 217
77.46
GitHub Action Run
24 daemon-5-space-workflow - 25297572842.24 04 May 2026 02:07AM UTC 103
30.86
GitHub Action Run
25 daemon-online-agent-sdk - 25297572842.25 04 May 2026 02:08AM UTC 304
18.95
GitHub Action Run
26 daemon-online-rewind-2 - 25297572842.26 04 May 2026 02:08AM UTC 304
19.59
GitHub Action Run
27 daemon-online-features-2 - 25297572842.27 04 May 2026 02:08AM UTC 304
19.31
GitHub Action Run
28 daemon-online-rpc-3 - 25297572842.28 04 May 2026 02:08AM UTC 304
16.89
GitHub Action Run
29 daemon-online-websocket - 25297572842.29 04 May 2026 02:07AM UTC 304
15.34
GitHub Action Run
Source Files on build 25297572842
  • Tree
  • List 531
  • Changed 5
  • Source Changed 3
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #25297572842
  • e473ede2 on github
  • Prev Build on dev (#25290178787)
  • Next Build on dev (#25324755337)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc