Add inline 'Create pull request' confirmation for completed tasks without PRs#319629
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an inline, opt-in “Create pull request” confirmation at the end of v2 Task API session history when a task completes without an attached PR, and wires a new backend API call to materialize the PR on demand.
Changes:
- Extend the v2 task backend surface with
createPullRequestForTask(...)and disable auto-PR creation on task creation (create_pull_request: false). - Append a
ChatResponseConfirmationPart(“Create pull request”) to completed/idle PR-less task histories and route its click handling via a newkind: 'create-pr'confirmation discriminator. - Add tests covering the inline confirmation rendering, create-PR delegation plumbing, URL repo parsing, and confirmation metadata validation/back-compat.
Show a summary per file
| File | Description |
|---|---|
| src/vs/monaco.d.ts | Minor doc alignment for folding markers comment. |
| extensions/copilot/src/extension/chatSessions/vscode/cloudAgentBackend.ts | Adds v2 backend API shape for creating PRs after task completion. |
| extensions/copilot/src/extension/chatSessions/vscode-node/test/copilotCloudSessionsProvider.spec.ts | Adds tests for inline create-PR confirmation, backend behavior, URL parsing, and metadata validation. |
| extensions/copilot/src/extension/chatSessions/vscode-node/taskApiBackend.ts | Disables auto-PR creation on task create and implements createPullRequestForTask; exports parseRepoFromTaskUrl. |
| extensions/copilot/src/extension/chatSessions/vscode-node/copilotCloudSessionsProvider.ts | Adds create-PR confirmation discriminator routing + handler and passes inline create-PR context into history building. |
| extensions/copilot/src/extension/chatSessions/vscode-node/copilotCloudSessionContentBuilder.ts | Appends the inline “Create pull request” confirmation to task history when appropriate. |
| extensions/copilot/src/extension/chatSessions/vscode-node/copilotCLIChatSessions.ts | Updates delegation metadata to include kind: 'delegation'. |
Copilot's findings
- Files reviewed: 6/7 changed files
- Comments generated: 4
|
const prInfo = await this.cloudSessionProvider.delegate(request, stream, context, token, { |
…ega/agents/autopilot-button-implementation
dmitrivMS
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.
Introduce an inline confirmation button for creating pull requests after tasks complete without one. This change enhances user experience by allowing users to opt-in for PR creation directly from the task history.