11

GitHub Copilot stopped working after it asked to restart vscode for the last update I installed, right now it doesn't even show the icon and there are no suggestions either, it's as if it wasn't installed.

enter image description here

I unistalled everything, even the vscode itself, deleting all the files and configuringicon in case there was a conflict or error, but the extension still does not work.

If anyone knows how to fix it or what is causing the error, I would be very grateful.

John James
  • 341
  • 3
  • 10
  • 1
    I am having this same problem, in both Copilot and Copilot Nightly. I can see that it fails to start by going to `View` > `Output` > Select `Extension Host` in the dropdown: `[error] Activating extension GitHub.copilot failed due to an error: [error] Error: Tests: either GH_COPILOT_TOKEN, or GITHUB_TOKEN, must be set, or there must be a GitHub token from an app with access to Copilot in /Users/nolanbarry/.copilot-testing-gh-token. Run "npm run get_token" to get one.` With a stack trace pointing to the folder containing the copilot package. Tried `npm run get_token` in that folder, no luck. – Nolan B. Dec 17 '22 at 03:44
  • I was searching and researching, I think it is a problem of the extension because I have already seen several people commenting the same situation. – John James Dec 17 '22 at 03:55
  • It's worth noting - For a single file, CoPilot still worked. When I opened a folder, I got this problem. The solution from Nolan B, fixed it for me. – user1567453 Jun 06 '23 at 07:17

1 Answers1

20

Rolling back to the previous version (1.63.7601) fixed it for me.

  • Click on extensions icon on left menu bar
  • Search for Copilot
  • Click the settings cog > Install another version
  • Select 1.63.7601
  • Reload VSCode

Edit 4/10/2023: The specific version listed above was the most recent working version at time of posting. Rolling back to any recent version should fix this issue if a new version of Copilot breaks again.

Nolan B.
  • 427
  • 1
  • 4
  • 9
  • 3
    Going to an old version worked for me too with the latest VSCode (1.77.1). Had to switch from GitHub Copilot v1.79.10634 back to v1.78.9758. They'll probably fix this but sharing in case someone else has issues. – jiminy Apr 09 '23 at 15:10
  • I found that it works when opening a SINGLE FILE using "File --> Open File..." but stops working when opening a folder. When I downgrade to an earlier version, it works for everything. – user1567453 Jun 13 '23 at 05:56