[cherry-pick] chat: restore GitHub issue and PR context attachments - #334620
Merged
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Unresolved merge conflicts, compilation failures, and an attachment replacement bug block approval.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Restores pasted GitHub issue and pull-request URLs as context attachments while preserving prompt text.
Changes:
- Creates and synchronizes GitHub URL attachments.
- Updates attachment rendering and keyboard handling.
- Adds regression coverage for paste and composer behavior.
File summaries
| File | Review |
|---|---|
src/vs/workbench/contrib/chat/test/browser/widget/input/editor/chatPasteProviders.test.ts |
Tests GitHub URL paste behavior; no unresolved issue identified. |
src/vs/workbench/contrib/chat/test/browser/widget/chatListRenderer.test.ts |
Critical: Contains unresolved merge markers. |
src/vs/workbench/contrib/chat/browser/widget/input/editor/chatPasteProviders.ts |
Critical: Contains unresolved merge markers in two hunks. |
src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputReferenceDecorations.ts |
Nit: Adds unused compact-reference decoration code that should remain deleted. |
src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.ts |
Critical: References undeclared isAnchorTarget. |
src/vs/sessions/contrib/chat/test/browser/newChatInput.test.ts |
Critical: Multiple unresolved conflicts and missing import; moderate: fake deduplication differs from production. |
src/vs/sessions/contrib/chat/common/newChatContextIds.ts |
Adds metadata for input-generated GitHub attachments; no unresolved issue identified. |
src/vs/sessions/contrib/chat/browser/newChatInput.ts |
Critical: Unresolved conflicts prevent compilation; moderate: explicit attachments cannot replace generated attachments with the same ID. |
Review details
- Files reviewed: 8/8 changed files
- Comments generated: 14
- Review effort level: Balanced
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Paste cancellation handling and accessible attachment announcements remain unresolved.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 7/7 changed files
- Comments generated: 2
- Review effort level: Balanced
SteVen Batten (sbatten)
previously approved these changes
Sep 4, 2026
Megan Rogge (meganrogge)
enabled auto-merge (squash)
September 5, 2026 00:02
Megan Rogge (meganrogge)
disabled auto-merge
September 5, 2026 00:02
Megan Rogge (meganrogge)
changed the base branch from
release/1.136
to
release/1.137
September 5, 2026 00:07
Megan Rogge (meganrogge)
dismissed
SteVen Batten (sbatten)’s stale review
September 5, 2026 00:07
The base branch was changed.
* chat: restore GitHub issue and PR context attachments Revert compact inline references for pasted GitHub issue and pull request URLs until attachment rendering is unified. Restore automatic context attachment synchronization in the Agents composer.\n\nRefs #334542\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * chat: attach pasted GitHub links as context Keep pasted issue and pull request URLs in the prompt while adding context attachments in regular Chat. Share URL parsing with the Agents composer and preserve undo behavior.\n\nRefs #334548\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * chat: use semantic icons for GitHub context Represent pasted GitHub links as generic context so issue and pull request pills render their respective Codicons without generic pasted-content chrome.\n\nRefs #334548\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * chat: preserve request link interactions Reject invalid GitHub issue and pull request URL continuations, and keep nested request links keyboard- and pointer-operable when inline request editing is enabled.\n\nRefs #334548\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * test: avoid forwarding flatMap index as metadata Wrap the GitHub attachment parser callback so Array.prototype.flatMap does not pass its numeric index into the optional metadata parameter.\n\nRefs #334548\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Megan Rogge (meganrogge)
force-pushed
the
cherry-pick/334544
branch
from
September 5, 2026 00:11
810764d to
50f10f6
Compare
Megan Rogge (meganrogge)
enabled auto-merge (squash)
September 5, 2026 00:25
TylerLeonhardt
approved these changes
Sep 5, 2026
roblourens
approved these changes
Sep 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.
Cherry-pick of #334544 from
main.Fixes #334548
Part of #334542
Summary
We only want to render Github issues/PRs as attachments when others get special treatment as well.
chat.pasteGitHubLinksAsReferencessetting and compact-reference serialization/rendering supportValidation
npm run transpile-client./scripts/test.sh --run src/vs/workbench/contrib/chat/test/browser/attachments/chatVariables.test.ts --run src/vs/workbench/contrib/chat/test/browser/widget/input/editor/chatPasteProviders.test.ts --run src/vs/workbench/contrib/chat/test/browser/widget/chatListRenderer.test.ts --run src/vs/workbench/contrib/chat/test/common/requestParser/chatRequestParser.test.ts --run src/vs/sessions/contrib/chat/test/browser/newChatInputPaste.test.ts --run src/vs/sessions/contrib/chat/test/browser/newChatInput.test.ts(122 passing, 1 pending)Screenshot