Handing a Copilot session off to the editor
An agent can carry a change most of the way, but review, line-level edits, and local testing belong in the editor. The GitHub Copilot app supports that transition: a session can be opened directly in VS Code with its conversation, code changes, and working context intact, so the work is continued rather than restarted.
What transfers with the session
A session is more than a set of modified files. It records the task, the plan, and the conversation that produced the changes — the material you need to understand why Copilot chose a given implementation or to ask for a revision. None of it has to be summarized or copied into a new chat before switching editors.
From the session, choose Open in VS Code; if several editors or VS Code installations are offered, pick one. VS Code then opens the project in the worktree associated with the session and shows that session in the Copilot sidebar, keeping three things connected:
- Session context: the task, plan, and conversation stay available.
- Diff: the files and lines the agent changed are ready for review.
- Worktree: the same isolated working tree the session used.
Reviewing the diff and editing by hand
Open the Source Control view to list changed files, then inspect them line by line as you would any proposed change. The checks worth making:
- The code solves the requested problem.
- It follows the repository's conventions.
- Error states and edge cases are handled appropriately.
- Tests cover the behavior that changed.
- No unrelated files or behaviors were modified.
Where the preserved conversation leaves something unclear, keep prompting in the sidebar:
Explain why you changed this function instead of adding a new helper. Identify any behavior this could affect.
You can also ask Copilot for another change without restating the task, since the session and worktree remain linked. Manual edits go straight into the session's existing worktree, which suits adjustments that are faster by hand — refining a label or error message, renaming a variable, adjusting layout or styling, adding a missing test case, or applying a repository-specific convention. No files need to be copied between directories and no branch has to be re-created.
Local verification and further prompting
Use the integrated terminal for the project's normal validation workflow. Exact commands vary by repository; for web apps they may include npm install, npm test, npm run lint, and npm run dev. Agent-generated code deserves the same treatment as a colleague's: run the tests, inspect failures, and confirm behavior yourself. If the dev server prints a localhost URL, open it — in VS Code's integrated browser where your setup supports it — and for UI changes check both the requested behavior and nearby states, such as different viewport sizes and loading, empty, and error states.
After that, pick whichever mode fits the next step: prompt Copilot for repository-wide analysis or repetitive edits, edit directly when you know exactly what you want, or iterate between the two. For example, following a manual UI tweak, ask:
Add a test for the updated label and run the relevant test file. Do not modify unrelated components.
Because the original session is still active, Copilot has the context to interpret "the updated label."
Committing, pushing, and the pull request
Review the final diff once more, then commit and push from the Source Control view or the terminal:
git statusgit addgit commit -m "Refine session changes"git push
Follow your repository's usual branch, commit, review, and approval practices. Since VS Code opened the worktree and branch tied to the session, pushing updates the pull request already tracking that work — there is no need to move files into another checkout or reconnect the work to the PR by hand. The upshot is a division of labor without a split in the work itself: Copilot takes on the larger or repetitive implementation, you take over in the editor for review, targeted changes, local testing, and polish, and the result ships through the same pull request.



