copilot-emacs / copilot.el

An unofficial Copilot plugin for Emacs.
MIT License
1.71k stars 122 forks source link

Compatibility issues with smartparens #310

Open jimeh opened 1 month ago

jimeh commented 1 month ago

copilot-mode doesn't play nice with smartparens-mode, specifically around {.

When the copilot overlay is visible and next character in the Copilot suggestion is ", manually typing a double quote allows smartparens to insert the matching end character.

However when the next character is {, typing that character seems to prevent smartparens from inserting the matching closing character.

Below is a screen recording of Copilot suggesting both " and {. After typing each character I use C+p to move the cursor up a line to clear the copilot overlay.

https://github.com/copilot-emacs/copilot.el/assets/39563/dcd4b78d-234c-4f27-9eb5-f1181d37f599