Send repoInfo telemetry for each repo in multi-repo workspaces#320054
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the Copilot extension’s RepoInfoTelemetry so that, in multi-repo workspaces, it emits request.repoInfo telemetry once per repository (bounded to a small cap) instead of only for the active repository. This improves visibility for scenarios like git.autoRepositoryDetection: 'subFolders' with many repos/submodules while keeping single-repo behavior intact.
Changes:
- Emit repoInfo telemetry per repository (with
repoIndex,repoCount, andisActiveRepository) and cap processing to 5 repos per request while always including the active repo. - Scope filesystem watchers to the repo root so changes in sibling repos don’t invalidate diff results.
- Add test coverage for multi-repo emission, capping behavior, and per-repo end-event gating.
Show a summary per file
| File | Description |
|---|---|
| extensions/copilot/src/extension/prompt/node/repoInfoTelemetry.ts | Refactors repoInfo telemetry to iterate over repositories (capped), adds repo indexing/active markers, and scopes file watching per repo. |
| extensions/copilot/src/extension/prompt/node/test/repoInfoTelemetry.spec.ts | Adds multi-repo unit tests and adjusts git service mocking to support repo list semantics. |
Copilot's findings
- Files reviewed: 2/2 changed files
- Comments generated: 1
roblourens
approved these changes
Jun 5, 2026
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.
The repoInfo telemetry event was previously emitted only for the active repository on each chat request. In multi-repo workspaces (and especially long-tail cases like git.autoRepositoryDetection: 'subFolders' with many submodules), this dropped visibility into all the other repos in scope. This PR extends RepoInfoTelemetry to emit one event per repository, while bounding cost and preserving all existing behavior for single-repo workspaces.