github / github/copilot-cli

`Remote session disabled: could not resolve repository` when using `/remote` on an organization repo

Aberta
#2,751 8 comentários 13 reações 0 responsáveis Ver no GitHub
area:agents area:enterprise
Linguagem predominante
Shell
Estrelas
11.2k
Forks
1.9k
Merge médio
14h 16min
PRs com merge (30d)
6

Descrição

### Describe the bug

When running the `/remote` command in Copilot CLI v1.0.28 inside a repository owned by a GitHub organization, the following error is shown:

```
Remote session disabled: could not resolve repository
```

### Affected version

v1.0.28 (copilot CLI)

### Steps to reproduce the behavior

1. Login with `/login` using a GitHub user account that is a confirmed member of the organization.
2. Use a local clone of a repository owned by the organization.
3. Run the `/remote` command.
4. The error appears: `Remote session disabled: could not resolve repository`.

### Expected behavior

The `/remote` session should start successfully, since:
- The repository exists under the organization.
- The logged-in user is a valid organization member.
- The org admin has enabled remote access for the user (without this, `/remote` cannot be invoked at all).

### Additional context

- Re-logging in with `/login` does not help.
- The org admin confirmed remote access is enabled.
- It appears Copilot CLI may be attempting to resolve the repo under the logged-in user's personal account, instead of the organization.
- This is similar to #1328 (wrong repo owner resolution), but here the error is blocking `/remote` usage rather than failing MCP commands after connection.
- OS: windows 11
- Terminal: power shell

Guia de contribuição

Abrir o guia de contribuição

Direção de pesquisa

Comece no ponto de entrada do comando `/remote` e rastreie a resolução do repositório após `/login` quando o clone local pertence a uma organização. Reproduza com o repositório pertencente à organização relatado e compare o proprietário resolvido com o repositório local; considera-se concluído quando a sessão remota é iniciada para um membro confirmado da organização.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
github, shell
Domínio
authentication, cli
Tipo de issue
Bug
Dificuldade
4/5
Tempo estimado
3-5 dias
Status de atividade
Pouca atividade
Clareza
Razoavelmente clara
Facilidade para iniciantes
48/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.