Skip to content

fix: check both qwen-code auth keys with fallback#28

Closed
ARIFCSE10 wants to merge 1 commit intoslkiser:mainfrom
ARIFCSE10:fix/qwen-code-auth-key-name
Closed

fix: check both qwen-code auth keys with fallback#28
ARIFCSE10 wants to merge 1 commit intoslkiser:mainfrom
ARIFCSE10:fix/qwen-code-auth-key-name

Conversation

@ARIFCSE10
Copy link
Copy Markdown

@ARIFCSE10 ARIFCSE10 commented Mar 24, 2026

Summary

The qwen-code provider shows as disabled unavailable in /quota_status even when the user has properly connected Qwen Code.

Root Cause

The opencode-qwencode-auth plugin stores OAuth credentials under the key "qwen-code" in auth.json.

However, this plugin was looking for the key "opencode-qwencode-auth" instead.

Fix

const qwen = auth?.["qwen-code"] ?? auth?.["opencode-qwencode-auth"];
  • Primary key: "qwen-code" (correct key from opencode-qwencode-auth plugin)
  • Fallback key: "opencode-qwencode-auth" (backward compatibility)

Files Changed

  • src/lib/qwen-auth.ts: Check both auth keys with nullish coalescing fallback

@ARIFCSE10 ARIFCSE10 force-pushed the fix/qwen-code-auth-key-name branch from 87a9ad8 to 1d0d2e0 Compare March 24, 2026 10:14
@ARIFCSE10 ARIFCSE10 changed the title fix: qwen-code auth key name mismatch causing disabled unavailable status fix: check both qwen-code auth keys with fallback Mar 24, 2026
@ARIFCSE10 ARIFCSE10 force-pushed the fix/qwen-code-auth-key-name branch 2 times, most recently from 7277bb0 to e9a65a9 Compare March 24, 2026 10:18
@ARIFCSE10 ARIFCSE10 force-pushed the fix/qwen-code-auth-key-name branch from e9a65a9 to 7debe5d Compare March 24, 2026 10:19
@slkiser
Copy link
Copy Markdown
Owner

slkiser commented Mar 25, 2026

Fixed in 2.11.0

@slkiser slkiser closed this Mar 25, 2026
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.

2 participants