Repository navigation
fix(tips): stop recommending /login when providers already have credentials - #2678
Merged
Merged
Conversation
…ntials Home tips forced the /login tip whenever auth.json was empty, even if env or mimocode.jsonc API keys were already present. Gate on known credential fields (key, source=env, options.apiKey) across computed providers instead. Bare list membership does not count — mimo is always listed.
yanyihan-xiaomi
force-pushed
the
fix/tips-login-credential-gate
branch
from
October 19, 2026 10:11
bb6bd85 to
ec4c1a6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/logintip wheneverauth.jsonwas empty, even if the user already had API keys in env ormimocode.jsonc.key,source === "env", or non-emptyoptions.apiKey) — one rule that covers env, config, and auth-store API keys.providerblocks still recommend/login(accepted gap).Verification
bun test test/cli/cmd/tui/tips-view.test.ts— 11 pass / 0 failbun run typecheck— PASSFollow-up
key/options.apiKey(e.g. Copilot setsapiKey: "") still show/login. Codex/xAI setOAUTH_DUMMY_KEYand suppress it. Aligning plugin auth loaders is a separate change.