github / github/app

Collection new-session flow treats parent folder as a Git repository

オープン
#3,286 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
triage
主要言語
言語のデータがありません
スター
2.1k
フォーク
153
PR マージ指標
30日以内にマージされた PR はありません

説明

## Affected version
GitHub Copilot app 1.1.14 on macOS 26.6.2.

## What happened?
A parent folder with no `.git` directory contains three direct child Git repositories, all on `main`. After adding the parent through **Projects -> + -> Open folder**, the app correctly registers it as a collection.

Opening **New session** for the collection shows generic single-repository controls (Project: collection name, Workspace: New worktree, Branch: main). The child repositories are not listed, so their branches and checkout modes cannot be selected.

Logs show the branch resolver targeting the non-Git parent:

```
Failed to get current branch path=~/gitrepos/spec-forge-all
error=git ["symbolic-ref", "HEAD"] failed:
fatal: not a git repository (or any of the parent directories): .git
```

The same failure occurs for `git worktree list`, `for-each-ref`, and `git fetch` against the parent.

## Steps to reproduce
1. Create a parent folder containing multiple direct child Git repositories, with no `.git` at the parent.
2. Add the parent using **Projects -> + -> Open folder**.
3. Click **New session** for the collection.
4. Observe one branch selector for the parent and no child-repository list.

## Expected behavior
Enumerate collection members and allow branch/checkout selection for each child. Run Git branch commands against each child, not the parent folder.

## Additional context
**Local repository** is a partial workaround but does not restore isolated multi-repository worktrees or per-repository branch selection. Related but narrower: #786 covers per-repository default branches.

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、collection の New session フローとログに表示される branch resolver を追跡し、その後、3 つの直接の子リポジトリを含み、親の .git ディレクトリを持たない親フォルダーで再現します。完了条件は、子リポジトリがリポジトリごとの branch と checkout の選択肢付きで一覧表示され、Git branch、worktree、ref、fetch コマンドが親ではなく各子に対して実行されることです。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
git
領域
desktop, tooling
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
活発
明瞭さ
明確に書かれている
初心者へのやさしさ
72/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。