Repository navigation
Conversation
NabiBukhsh-AI
left a comment
There was a problem hiding this comment.
Thanks for working on this @ziuus I took a look through the changes and noticed a few edge cases and repository conventions that might help get this merged smoothly:
1. Missing Changelog Fragment
OmniRoute requires a changelog fragment for new features. Adding one under changelog.d/features/18181-antigravity-local-import.md will keep the CI checks green.
2. Scope Creep in bin/cli/
There are changes included in bin/cli/commands/doctor.mjs, runtime.mjs, setup-claude.mjs, and nativeDeps.mjs regarding better-sqlite3 and npm install-scripts. Extracting these into a separate PR will keep this PR atomic and easier for maintainers to review.
3. Cross-Platform Path Detection in agyAuthImport.ts
In detectLocalAgyTokenRaw():
- The path check for
state.vscdbcurrently only checks Linux paths (~/.config/Antigravity/...). - On macOS, Antigravity/VS Code stores user state in:
~/Library/Application Support/Antigravity/User/globalStorage/state.vscdb - On Windows, it is under:
%APPDATA%\Antigravity\User\globalStorage\state.vscdb
Adding platform-aware path resolution (process.platform === 'darwin', etc.) will allow macOS and Windows users to use local import as well.
4. Direct sqlite3 CLI Invocation
await execFileAsync("sqlite3", [dbPath, ...]) relies on the host having the sqlite3 CLI binary installed on $PATH. On systems without the command-line tool installed, this will throw ENOENT. Since OmniRoute already bundles better-sqlite3, reading the SQLite DB directly or adding a fallback prevents silent detection failures.
5. i18n Sync
New keys were added to src/i18n/messages/en.json. Running npm run i18n:sync will keep the other locale dictionaries synchronized so docs/i18n checks pass.
- Add detectLocalAgyTokenRaw cascade supporting Linux Secret Service keyring, AGY_TOKEN_FILE, default paths, and IDE SQLite database - Update /api/providers/agy-auth/apply-local route to use multi-source auto-detection - Add ImportAgyAuthModal with 1-click local detection, single file/paste, and bulk import - Add 'Import auth' buttons to ConnectionsHeaderToolbar and EmptyConnectionsPlaceholder - Wire modal state in ProviderDetailPageClient and ProviderModalsPanel - Add unit tests for detectLocalAgyTokenRaw (7/7 pass)
9fe942e to
db37b5a
Compare
|
Thanks for the thorough review @NabiBukhsh-AI! All 5 points have been addressed in the latest update:
All unit tests pass (7/7). Ready for review! |
…l import - Add changelog fragment changelog.d/features/18181-antigravity-local-import.md - Add cross-platform state.vscdb paths for macOS, Windows, and Linux - Use driverFactory with graceful sqlite3 fallback avoiding ENOENT - Sync UI localization dictionaries via i18n:sync-ui
db37b5a to
4565bb6
Compare
|
Addressed all 5 review points in commit
All unit tests pass ( |
Resolves the agyAuthImport.ts import conflict by keeping the release's @/lib/db/providers import (no localDb barrel, Hard Rule #2) and restores every non-English locale catalog to the release side, dropping the stale v3.8.50 key re-orderings and the pt-BR __MISSING__ marker; in.json was removed on the release. Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
…e Antigravity import modal - detectLocalAgyTokenRaw no longer reads the Antigravity IDE state.vscdb: its apiKey was stored as both access and refresh token without a verified payload shape; the cascade is split into small helpers (AGY_TOKEN_FILE, keyring with refresh token, CLI token files, AgentControl profiles) and keeps the static no_local_login message. - ImportAgyAuthModal routes every label and toast through t() (46 new providers.agyImport* keys, translated in all 66 locales), uses the kit SegmentedControl/Input/Textarea/Checkbox and is split into tab components and hooks under the complexity ratchets. - Tests: AGY_TOKEN_FILE is restored with delete when it was unset; new cases for the 404 no_local_login path with an isolated HOME, the default CLI token file, the IDE database being ignored, and the apply-local route (404 and malformed body). Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
…and isolate test keyring
…lease/v3.8.53 base
…ort and add Token Harbor free catalog evidence
…nce, test guards, and docs counts sync
…ger skill, update stryker tap tests, and ratchet vulnCount to 30
…ter test to serial
Summary
Adds an Import auth connection option and modal for Antigravity (
agy/ Google Cloud Code), mirroring the existing local import patterns for Codex and Claude CLI.Related Issues
Changes
src/lib/oauth/utils/agyAuthImport.ts):secret-tool(service=gemini,username=antigravity)AGY_TOKEN_FILEenv override~/.gemini/antigravity-cli/,~/.config/agentcontrol/profiles/*/)state.vscdb)src/app/api/providers/agy-auth/apply-local/route.ts):detectLocalAgyTokenRawcascade.ImportAgyAuthModal.tsx,ConnectionsHeaderToolbar.tsx,EmptyConnectionsPlaceholder.tsx):ProviderDetailPageClientandProviderModalsPanel.tests/unit/agy-auth-import.test.ts):detectLocalAgyTokenRawsuite.