Long delay on :q when exiting Neovim with copilot.vim enabled, even with session counting patches — any suggestions?
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 30/100
Piste de recherche
Commencez par reproduire le délai d'environ 10 secondes lors de l'exécution de :q avec copilot.vim activé après une période d'inactivité, en utilisant les versions signalées de Neovim, Node.js et Linux. Examinez la gestion de VimLeavePre, le groupe d'autocommandes github_copilot et l'arrêt de copilot node-process décrit dans l'issue. Le travail est terminé lorsque le comportement de sortie bloquant a été identifié et résolu sans désactiver les fonctionnalités de Copilot, et que le résultat a été vérifié au cours d'une seule session inactive.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Hi,
I’m experiencing a significant delay (~10 seconds) when quitting Neovim (:q) with copilot.vim enabled, and this happens even with a single Neovim session after it has been idle for a while.
To mitigate this, I’ve tried:
Adding a session counter (both Lua in init.lua and Vimscript in a plugin/copilot_session.vim patch) to track how many Neovim sessions with Copilot are active.
On VimLeavePre, only calling Copilot disable and killing the copilot node process when the last session exits, skipping it otherwise to avoid the stall.
Clearing Copilot’s own VimLeavePre autocmd group (github_copilot) in all but the last session to prevent multiple shutdown hooks running.
Avoiding forcibly killing node processes except on the last session exit.
However, the stall still occurs on quit even when only one Neovim session is open and idle. The copilot node process appears to be killed during exit, and I suspect Copilot’s internal shutdown logic is blocking Neovim exit.
My questions are:
Are there known issues in copilot.vim causing blocking delays on exit after idle?
Is there an official or recommended way to make Copilot’s shutdown asynchronous or non-blocking?
How can I reliably prevent the exit delay without disabling Copilot’s essential functionality?
Are there patches, config workarounds, or plugin updates that address this problem?
Thanks in advance for any insights or help!
NVIM v0.11.1
Build type: RelWithDebInfo
LuaJIT 2.1.1741730670
node --version
v22.15.1
Linux 4.18.0-477.21.1.el8_8.x86_64 #1 SMP Thu Jul 20 08:38:27 EDT 2023 x86_64 x86_64 x86_64 GNU/Linux
- Langage dominant
- Vim Script
- Étoiles
- 11.7k
- Forks
- 812
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Guide de contribution
Ouvrir le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de github/copilot.vim
-
No link to DeepWiki Ouverte
Difficulté 1/5 Moins d'une heure Accessibilité débutants 82/100
github/copilot.vim#303 ·
-
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
github/copilot.vim#276 · 1 commentaire · 1 réaction ·
-
Neomarley Ouverte
Difficulté 5/5 Plus d'une semaine Accessibilité débutants 1/100
github/copilot.vim#304 · 1 réaction ·
-
Readme. Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 20/100
github/copilot.vim#302 · 4 commentaires ·
-
Micky Ouverte
Difficulté 5/5 Plus d'une semaine Accessibilité débutants 1/100
github/copilot.vim#301 ·
Toutes les issues de github/copilot.vim
Issues similaires
-
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
vercel-labs/just-bash#464 ·
-
Bug
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100
Automattic/safe-publish#594 ·
-
bug
Difficulté 1/5 Moins d'une heure Accessibilité débutants 85/100
-
Difficulté 2/5 1-3 heures Accessibilité débutants 65/100
-
bug feat:crypto feat:utils
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100