github / github/copilot-cli

Copilot Free in GitHub Codespaces: "No model available" after update, Auto selection, token isolation, and re-login

未关闭
#4,405 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

area:authentication area:models
主要语言
Shell
星标
11.2k
派生
1.9k
平均合并
14 小时 16 分钟
30 天内合并 PR
6

描述

Describe the bug

GitHub Copilot CLI launches successfully in a GitHub Codespace, but every prompt immediately fails with:

Execution failed: Error: No model available. Check policy enablement under GitHub Settings > Copilot

The account is on GitHub Copilot Free. GitHub's documentation states that Copilot CLI is available with all Copilot plans and that Copilot Free users should use Auto model selection.

The problem still occurs after all of the following:

  • Updating Copilot CLI with copilot update
  • Selecting Auto with /model auto
  • Launching the CLI without the Codespaces-provided authentication environment variables
  • Signing out and signing in again with /logout and /login

The screenshot taken before the update also shows Remaining reqs.: 0%. If the actual cause is an exhausted Free-plan request allowance, the current error message is misleading because it reports a model/policy problem instead of a usage-limit condition.

Affected version

v1.0.78 after running copilot update (initially v1.0.3; the issue persists after updating)

Steps to reproduce the behavior
  1. Open a GitHub Codespace.

  2. Run copilot update.

  3. Launch Copilot CLI without the Codespaces token variables:

    env -u COPILOT_GITHUB_TOKEN -u GH_TOKEN -u GITHUB_TOKEN -u COPILOT_MODEL copilot
    
  4. Run /logout, then /login, and authenticate again with the Copilot Free account.

  5. Run /model auto.

  6. Enter a minimal prompt such as:

    Reply with "hello".
    
  7. Observe the error:

    Execution failed: Error: No model available. Check policy enablement under GitHub Settings > Copilot
    

The same failure occurs both with the normal Codespaces environment and with the token variables removed for the Copilot process.

Expected behavior

Copilot Free should either:

  1. Respond using Auto model selection, because Copilot CLI is documented as available with all Copilot plans; or
  2. If the Free-plan request allowance is exhausted, display a clear quota/usage-limit message.

It should not report that no model is available because of policy enablement when the user is on an individual Copilot Free plan and Auto is selected.

Additional context

Environment:

  • GitHub Codespaces
  • VS Code integrated terminal
  • Linux Codespace
  • Copilot plan: Copilot Free
  • Initial CLI version shown in the screenshot: v1.0.3
  • Update offered in the screenshot: v1.0.78
  • Updated with copilot update; the problem still reproduces
  • /model auto does not resolve the problem
  • Removing COPILOT_GITHUB_TOKEN, GH_TOKEN, GITHUB_TOKEN, and COPILOT_MODEL for the Copilot process does not resolve the problem
  • Re-authenticating with /logout and /login does not resolve the problem
  • The initial screenshot shows Remaining reqs.: 0%

Related older reports:

Screenshot of the exact terminal state and error:

GitHub Copilot CLI showing No model available in a Codespace terminal

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 GitHub Codespace 使用已记录的 environment-unset copilot command 复现,然后测试 /logout、/login 和 /model auto,同时检查报告的剩余请求数。跟踪 CLI 路径,查明它如何将模型可用性或配额响应转换为“No model available”;完成标准是 Copilot Free 要么收到响应,要么得到清晰的使用限制消息。

由索引模型根据 Issue 内容生成。

评估

技术栈
github, shell
领域
cli
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
冷清
描述清晰度
基本清楚
新手友好度
42/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。