GNU bug report logs - #70927
30.0.50; track-changes assertion when shutting down eglot

Previous Next

Package: emacs;

Reported by: Steven Allen <steven <at> stebalien.com>

Date: Mon, 13 May 2024 22:22:02 UTC

Severity: normal

Found in version 30.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

To reply to this bug, email your comments to 70927 AT debbugs.gnu.org.
There is no need to reopen the bug first.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Mon, 13 May 2024 22:22:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Steven Allen <steven <at> stebalien.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 13 May 2024 22:22:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 30.0.50; track-changes assertion when shutting down eglot
Date: Mon, 13 May 2024 15:21:37 -0700
When `eglot-autoshutdown` is set, killing eglot buffers fails with a
track-changes assertion because, from what I can tell,
`eglot--signal-textDocument/didChange` is called when
`eglot--track-changes` is `nil`.

Backtrace:

  cl--assertion-failed((memq id track-changes--trackers))
  track-changes-fetch(nil #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_136>)
  eglot--track-changes-fetch(nil)
  eglot--signal-textDocument/didChange()
  eglot--request(#<eglot-lsp-server eglot-lsp-server-10d3578e408f> :shutdown nil :timeout 1.5)
  eglot-shutdown(#<eglot-lsp-server eglot-lsp-server-10d3578e408f>)
  eglot--managed-mode(-1)
  eglot--managed-mode-off()
  kill-current-buffer()
  funcall-interactively(kill-current-buffer)
  command-execute(kill-current-buffer)

Reproduction:

1. Start emacs with `emacs -Q`.
2. Run `M-: (setopt eglot-autoshutdown t) RET`
3. Open any file you have an LSP server for and run `M-x eglot RET`.
4. Kill the buffer.

In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, cairo version
 1.18.0) of 2024-05-13 built on Laptop
Repository revision: e86c4d8bdc8bdbc959a1f7f03576205ce707743e
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101013
System Description: Arch Linux

Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --mandir=/usr/share/man --with-gameuser=:games
 --with-modules --without-m17n-flt --without-selinux --without-pop
 --without-gconf --enable-link-time-optimization
 --with-native-compilation=yes --with-xinput2 --with-x-toolkit=no
 --without-toolkit-scroll-bars --without-xft --without-xaw3d
 --with-cairo-xcb --with-sound=no --with-tree-sitter --without-gpm
 --without-compress-install
 '--program-transform-name=s/\([ec]tags\)/\1.emacs/'
 'CFLAGS=-march=native -mtune=native -O2 -pipe -fno-plt -fexceptions
 -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security
 -fstack-clash-protection -fcf-protection -flto=auto' 'LDFLAGS=-Wl,-O1
 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now
 -Wl,-z,pack-relative-relocs -Wl,-z,noexecstack -flto=auto''

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG
LCMS2 LIBOTF LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY
OLDXMENU PDUMPER PNG RSVG SECCOMP SQLITE3 THREADS TIFF TREE_SITTER WEBP
X11 XDBE XIM XINPUT2 XPM ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: ELisp/l

Minor modes in effect:
  csv-field-index-mode: t
  org-super-agenda-mode: t
  windmove-mode: t
  rainbow-mode: t
  rainbow-delimiters-mode: t
  ligature-mode: t
  global-atomic-chrome-edit-mode: t
  i3bar-mode: t
  ednc-mode: t
  ws-butler-mode: t
  auto-compile-on-load-mode: t
  auto-compile-on-save-mode: t
  auto-compile-mode: t
  save-place-mode: t
  savehist-mode: t
  openwith-mode: t
  global-org-modern-mode: t
  goto-address-prog-mode: t
  eat-eshell-mode: t
  magit-todos-mode: t
  global-git-commit-mode: t
  dired-async-mode: t
  magit-auto-revert-mode: t
  server-mode: t
  recentf-mode: t
  global-treesit-auto-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  async-bytecomp-package-mode: t
  sudo-edit-indicator-mode: t
  global-auto-revert-mode: t
  vertico-mode: t
  corfu-popupinfo-mode: t
  global-corfu-mode: t
  corfu-mode: t
  isearch-mb-mode: t
  pixel-scroll-precision-mode: t
  global-hl-todo-mode: t
  hl-todo-mode: t
  all-the-icons-completion-mode: t
  marginalia-mode: t
  global-page-break-lines-mode: t
  page-break-lines-mode: t
  global-anzu-mode: t
  anzu-mode: t
  global-jinx-mode: t
  evil-goggles-mode: t
  global-evil-surround-mode: t
  evil-surround-mode: t
  global-evil-collection-unimpaired-mode: t
  evil-collection-unimpaired-mode: t
  evil-mode: t
  evil-local-mode: t
  desktop-environment-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  prettify-symbols-mode: t
  tab-bar-history-mode: t
  tab-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  window-divider-mode: t
  minibuffer-regexp-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch hides /usr/share/emacs/site-lisp/notmuch
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-wash hides /usr/share/emacs/site-lisp/notmuch-wash
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-tree hides /usr/share/emacs/site-lisp/notmuch-tree
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-tag hides /usr/share/emacs/site-lisp/notmuch-tag
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-show hides /usr/share/emacs/site-lisp/notmuch-show
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-query hides /usr/share/emacs/site-lisp/notmuch-query
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-print hides /usr/share/emacs/site-lisp/notmuch-print
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-parser hides /usr/share/emacs/site-lisp/notmuch-parser
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-mua hides /usr/share/emacs/site-lisp/notmuch-mua
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-message hides /usr/share/emacs/site-lisp/notmuch-message
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-maildir-fcc hides /usr/share/emacs/site-lisp/notmuch-maildir-fcc
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-lib hides /usr/share/emacs/site-lisp/notmuch-lib
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-jump hides /usr/share/emacs/site-lisp/notmuch-jump
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-hello hides /usr/share/emacs/site-lisp/notmuch-hello
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-draft hides /usr/share/emacs/site-lisp/notmuch-draft
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-crypto hides /usr/share/emacs/site-lisp/notmuch-crypto
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-compat hides /usr/share/emacs/site-lisp/notmuch-compat
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-company hides /usr/share/emacs/site-lisp/notmuch-company
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/notmuch-address hides /usr/share/emacs/site-lisp/notmuch-address
/home/steb/.cache/emacs/elpa/notmuch-20240406.1803/coolj hides /usr/share/emacs/site-lisp/coolj
/home/steb/.cache/emacs/elpa/protobuf-mode-20240222.1652/protobuf-mode hides /usr/share/emacs/site-lisp/protobuf-mode
/home/steb/.cache/emacs/elpa/transient-20240509.1849/transient hides /usr/share/emacs/30.0.50/lisp/transient
/home/steb/.cache/emacs/elpa/modus-themes-20240227.715/theme-loaddefs hides /usr/share/emacs/30.0.50/lisp/theme-loaddefs
/home/steb/.cache/emacs/elpa/org-9.6.30/ox hides /usr/share/emacs/30.0.50/lisp/org/ox
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-texinfo hides /usr/share/emacs/30.0.50/lisp/org/ox-texinfo
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-publish hides /usr/share/emacs/30.0.50/lisp/org/ox-publish
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-org hides /usr/share/emacs/30.0.50/lisp/org/ox-org
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-odt hides /usr/share/emacs/30.0.50/lisp/org/ox-odt
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-md hides /usr/share/emacs/30.0.50/lisp/org/ox-md
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-man hides /usr/share/emacs/30.0.50/lisp/org/ox-man
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-latex hides /usr/share/emacs/30.0.50/lisp/org/ox-latex
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-koma-letter hides /usr/share/emacs/30.0.50/lisp/org/ox-koma-letter
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-icalendar hides /usr/share/emacs/30.0.50/lisp/org/ox-icalendar
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-html hides /usr/share/emacs/30.0.50/lisp/org/ox-html
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-beamer hides /usr/share/emacs/30.0.50/lisp/org/ox-beamer
/home/steb/.cache/emacs/elpa/org-9.6.30/ox-ascii hides /usr/share/emacs/30.0.50/lisp/org/ox-ascii
/home/steb/.cache/emacs/elpa/org-9.6.30/org hides /usr/share/emacs/30.0.50/lisp/org/org
/home/steb/.cache/emacs/elpa/org-9.6.30/org-version hides /usr/share/emacs/30.0.50/lisp/org/org-version
/home/steb/.cache/emacs/elpa/org-9.6.30/org-timer hides /usr/share/emacs/30.0.50/lisp/org/org-timer
/home/steb/.cache/emacs/elpa/org-9.6.30/org-tempo hides /usr/share/emacs/30.0.50/lisp/org/org-tempo
/home/steb/.cache/emacs/elpa/org-9.6.30/org-table hides /usr/share/emacs/30.0.50/lisp/org/org-table
/home/steb/.cache/emacs/elpa/org-9.6.30/org-src hides /usr/share/emacs/30.0.50/lisp/org/org-src
/home/steb/.cache/emacs/elpa/org-9.6.30/org-refile hides /usr/share/emacs/30.0.50/lisp/org/org-refile
/home/steb/.cache/emacs/elpa/org-9.6.30/org-protocol hides /usr/share/emacs/30.0.50/lisp/org/org-protocol
/home/steb/.cache/emacs/elpa/org-9.6.30/org-plot hides /usr/share/emacs/30.0.50/lisp/org/org-plot
/home/steb/.cache/emacs/elpa/org-9.6.30/org-persist hides /usr/share/emacs/30.0.50/lisp/org/org-persist
/home/steb/.cache/emacs/elpa/org-9.6.30/org-pcomplete hides /usr/share/emacs/30.0.50/lisp/org/org-pcomplete
/home/steb/.cache/emacs/elpa/org-9.6.30/org-num hides /usr/share/emacs/30.0.50/lisp/org/org-num
/home/steb/.cache/emacs/elpa/org-9.6.30/org-mouse hides /usr/share/emacs/30.0.50/lisp/org/org-mouse
/home/steb/.cache/emacs/elpa/org-9.6.30/org-mobile hides /usr/share/emacs/30.0.50/lisp/org/org-mobile
/home/steb/.cache/emacs/elpa/org-9.6.30/org-macs hides /usr/share/emacs/30.0.50/lisp/org/org-macs
/home/steb/.cache/emacs/elpa/org-9.6.30/org-macro hides /usr/share/emacs/30.0.50/lisp/org/org-macro
/home/steb/.cache/emacs/elpa/org-9.6.30/org-loaddefs hides /usr/share/emacs/30.0.50/lisp/org/org-loaddefs
/home/steb/.cache/emacs/elpa/org-9.6.30/org-list hides /usr/share/emacs/30.0.50/lisp/org/org-list
/home/steb/.cache/emacs/elpa/org-9.6.30/org-lint hides /usr/share/emacs/30.0.50/lisp/org/org-lint
/home/steb/.cache/emacs/elpa/org-9.6.30/org-keys hides /usr/share/emacs/30.0.50/lisp/org/org-keys
/home/steb/.cache/emacs/elpa/org-9.6.30/org-inlinetask hides /usr/share/emacs/30.0.50/lisp/org/org-inlinetask
/home/steb/.cache/emacs/elpa/org-9.6.30/org-indent hides /usr/share/emacs/30.0.50/lisp/org/org-indent
/home/steb/.cache/emacs/elpa/org-9.6.30/org-id hides /usr/share/emacs/30.0.50/lisp/org/org-id
/home/steb/.cache/emacs/elpa/org-9.6.30/org-habit hides /usr/share/emacs/30.0.50/lisp/org/org-habit
/home/steb/.cache/emacs/elpa/org-9.6.30/org-goto hides /usr/share/emacs/30.0.50/lisp/org/org-goto
/home/steb/.cache/emacs/elpa/org-9.6.30/org-footnote hides /usr/share/emacs/30.0.50/lisp/org/org-footnote
/home/steb/.cache/emacs/elpa/org-9.6.30/org-fold hides /usr/share/emacs/30.0.50/lisp/org/org-fold
/home/steb/.cache/emacs/elpa/org-9.6.30/org-fold-core hides /usr/share/emacs/30.0.50/lisp/org/org-fold-core
/home/steb/.cache/emacs/elpa/org-9.6.30/org-feed hides /usr/share/emacs/30.0.50/lisp/org/org-feed
/home/steb/.cache/emacs/elpa/org-9.6.30/org-faces hides /usr/share/emacs/30.0.50/lisp/org/org-faces
/home/steb/.cache/emacs/elpa/org-9.6.30/org-entities hides /usr/share/emacs/30.0.50/lisp/org/org-entities
/home/steb/.cache/emacs/elpa/org-9.6.30/org-element hides /usr/share/emacs/30.0.50/lisp/org/org-element
/home/steb/.cache/emacs/elpa/org-9.6.30/org-duration hides /usr/share/emacs/30.0.50/lisp/org/org-duration
/home/steb/.cache/emacs/elpa/org-9.6.30/org-datetree hides /usr/share/emacs/30.0.50/lisp/org/org-datetree
/home/steb/.cache/emacs/elpa/org-9.6.30/org-cycle hides /usr/share/emacs/30.0.50/lisp/org/org-cycle
/home/steb/.cache/emacs/elpa/org-9.6.30/org-ctags hides /usr/share/emacs/30.0.50/lisp/org/org-ctags
/home/steb/.cache/emacs/elpa/org-9.6.30/org-crypt hides /usr/share/emacs/30.0.50/lisp/org/org-crypt
/home/steb/.cache/emacs/elpa/org-9.6.30/org-compat hides /usr/share/emacs/30.0.50/lisp/org/org-compat
/home/steb/.cache/emacs/elpa/org-9.6.30/org-colview hides /usr/share/emacs/30.0.50/lisp/org/org-colview
/home/steb/.cache/emacs/elpa/org-9.6.30/org-clock hides /usr/share/emacs/30.0.50/lisp/org/org-clock
/home/steb/.cache/emacs/elpa/org-9.6.30/org-capture hides /usr/share/emacs/30.0.50/lisp/org/org-capture
/home/steb/.cache/emacs/elpa/org-9.6.30/org-attach hides /usr/share/emacs/30.0.50/lisp/org/org-attach
/home/steb/.cache/emacs/elpa/org-9.6.30/org-attach-git hides /usr/share/emacs/30.0.50/lisp/org/org-attach-git
/home/steb/.cache/emacs/elpa/org-9.6.30/org-archive hides /usr/share/emacs/30.0.50/lisp/org/org-archive
/home/steb/.cache/emacs/elpa/org-9.6.30/org-agenda hides /usr/share/emacs/30.0.50/lisp/org/org-agenda
/home/steb/.cache/emacs/elpa/org-9.6.30/ol hides /usr/share/emacs/30.0.50/lisp/org/ol
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-w3m hides /usr/share/emacs/30.0.50/lisp/org/ol-w3m
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-rmail hides /usr/share/emacs/30.0.50/lisp/org/ol-rmail
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-mhe hides /usr/share/emacs/30.0.50/lisp/org/ol-mhe
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-man hides /usr/share/emacs/30.0.50/lisp/org/ol-man
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-irc hides /usr/share/emacs/30.0.50/lisp/org/ol-irc
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-info hides /usr/share/emacs/30.0.50/lisp/org/ol-info
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-gnus hides /usr/share/emacs/30.0.50/lisp/org/ol-gnus
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-eww hides /usr/share/emacs/30.0.50/lisp/org/ol-eww
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-eshell hides /usr/share/emacs/30.0.50/lisp/org/ol-eshell
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-doi hides /usr/share/emacs/30.0.50/lisp/org/ol-doi
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-docview hides /usr/share/emacs/30.0.50/lisp/org/ol-docview
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-bibtex hides /usr/share/emacs/30.0.50/lisp/org/ol-bibtex
/home/steb/.cache/emacs/elpa/org-9.6.30/ol-bbdb hides /usr/share/emacs/30.0.50/lisp/org/ol-bbdb
/home/steb/.cache/emacs/elpa/org-9.6.30/oc hides /usr/share/emacs/30.0.50/lisp/org/oc
/home/steb/.cache/emacs/elpa/org-9.6.30/oc-natbib hides /usr/share/emacs/30.0.50/lisp/org/oc-natbib
/home/steb/.cache/emacs/elpa/org-9.6.30/oc-csl hides /usr/share/emacs/30.0.50/lisp/org/oc-csl
/home/steb/.cache/emacs/elpa/org-9.6.30/oc-bibtex hides /usr/share/emacs/30.0.50/lisp/org/oc-bibtex
/home/steb/.cache/emacs/elpa/org-9.6.30/oc-biblatex hides /usr/share/emacs/30.0.50/lisp/org/oc-biblatex
/home/steb/.cache/emacs/elpa/org-9.6.30/oc-basic hides /usr/share/emacs/30.0.50/lisp/org/oc-basic
/home/steb/.cache/emacs/elpa/org-9.6.30/ob hides /usr/share/emacs/30.0.50/lisp/org/ob
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-tangle hides /usr/share/emacs/30.0.50/lisp/org/ob-tangle
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-table hides /usr/share/emacs/30.0.50/lisp/org/ob-table
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-sqlite hides /usr/share/emacs/30.0.50/lisp/org/ob-sqlite
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-sql hides /usr/share/emacs/30.0.50/lisp/org/ob-sql
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-shell hides /usr/share/emacs/30.0.50/lisp/org/ob-shell
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-sed hides /usr/share/emacs/30.0.50/lisp/org/ob-sed
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-screen hides /usr/share/emacs/30.0.50/lisp/org/ob-screen
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-scheme hides /usr/share/emacs/30.0.50/lisp/org/ob-scheme
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-sass hides /usr/share/emacs/30.0.50/lisp/org/ob-sass
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-ruby hides /usr/share/emacs/30.0.50/lisp/org/ob-ruby
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-ref hides /usr/share/emacs/30.0.50/lisp/org/ob-ref
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-python hides /usr/share/emacs/30.0.50/lisp/org/ob-python
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-processing hides /usr/share/emacs/30.0.50/lisp/org/ob-processing
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-plantuml hides /usr/share/emacs/30.0.50/lisp/org/ob-plantuml
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-perl hides /usr/share/emacs/30.0.50/lisp/org/ob-perl
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-org hides /usr/share/emacs/30.0.50/lisp/org/ob-org
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-octave hides /usr/share/emacs/30.0.50/lisp/org/ob-octave
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-ocaml hides /usr/share/emacs/30.0.50/lisp/org/ob-ocaml
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-maxima hides /usr/share/emacs/30.0.50/lisp/org/ob-maxima
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-matlab hides /usr/share/emacs/30.0.50/lisp/org/ob-matlab
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-makefile hides /usr/share/emacs/30.0.50/lisp/org/ob-makefile
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-lua hides /usr/share/emacs/30.0.50/lisp/org/ob-lua
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-lob hides /usr/share/emacs/30.0.50/lisp/org/ob-lob
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-lisp hides /usr/share/emacs/30.0.50/lisp/org/ob-lisp
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-lilypond hides /usr/share/emacs/30.0.50/lisp/org/ob-lilypond
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-latex hides /usr/share/emacs/30.0.50/lisp/org/ob-latex
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-julia hides /usr/share/emacs/30.0.50/lisp/org/ob-julia
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-js hides /usr/share/emacs/30.0.50/lisp/org/ob-js
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-java hides /usr/share/emacs/30.0.50/lisp/org/ob-java
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-haskell hides /usr/share/emacs/30.0.50/lisp/org/ob-haskell
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-groovy hides /usr/share/emacs/30.0.50/lisp/org/ob-groovy
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-gnuplot hides /usr/share/emacs/30.0.50/lisp/org/ob-gnuplot
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-fortran hides /usr/share/emacs/30.0.50/lisp/org/ob-fortran
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-forth hides /usr/share/emacs/30.0.50/lisp/org/ob-forth
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-exp hides /usr/share/emacs/30.0.50/lisp/org/ob-exp
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-eval hides /usr/share/emacs/30.0.50/lisp/org/ob-eval
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-eshell hides /usr/share/emacs/30.0.50/lisp/org/ob-eshell
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-emacs-lisp hides /usr/share/emacs/30.0.50/lisp/org/ob-emacs-lisp
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-dot hides /usr/share/emacs/30.0.50/lisp/org/ob-dot
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-ditaa hides /usr/share/emacs/30.0.50/lisp/org/ob-ditaa
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-css hides /usr/share/emacs/30.0.50/lisp/org/ob-css
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-core hides /usr/share/emacs/30.0.50/lisp/org/ob-core
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-comint hides /usr/share/emacs/30.0.50/lisp/org/ob-comint
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-clojure hides /usr/share/emacs/30.0.50/lisp/org/ob-clojure
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-calc hides /usr/share/emacs/30.0.50/lisp/org/ob-calc
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-awk hides /usr/share/emacs/30.0.50/lisp/org/ob-awk
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-R hides /usr/share/emacs/30.0.50/lisp/org/ob-R
/home/steb/.cache/emacs/elpa/org-9.6.30/ob-C hides /usr/share/emacs/30.0.50/lisp/org/ob-C

Features:
(shadow emacsbug semantic/symref/grep semantic/symref
semantic/util-modes semantic/util semantic semantic/tag semantic/lex
semantic/fw cedet modus-operandi-theme pulseaudio-control rust-ts-mode
c-ts-common toml-ts-mode vc-hg vc-bzr vc-src vc-sccs vc-svn vc-cvs
vc-rcs evil-collection-log-view log-view vc emacsql-sqlite-builtin
sqlite visual-wrap tex-mode use-package-ensure use-package-core checkdoc
package-lint-flymake package-lint evil-collection-finder finder lisp-mnt
info-colors evil-collection-helpful helpful cc-langs trace cl-print
evil-collection-edebug edebug info-look evil-collection-elisp-refs
elisp-refs iwindow bash-completion csv-mode sort tzc help-fns radix-tree
tramp-cmds tramp-cache time-stamp qp mm-archive notmuch-microdata
microdata link-hint avy mail-extr org-super-agenda ts ht org-habit
evil-org-agenda org-agenda secrets tabify org-capture timezone misearch
multi-isearch make-mode consult-project-extra buffer-move textsec
uni-scripts idna-mapping ucs-normalize uni-confusable textsec-check shr
pixel-fill kinsoku url-file find-dired hippie-exp consult-xref
all-the-icons-ibuffer ibuf-ext evil-collection-ibuffer ibuffer
ibuffer-loaddefs cape ffap go-ts-mode tramp-rclone tramp-fuse windmove
evil-collection-eglot eglot external-completion jsonrpc
evil-collection-ert ert ewoc evil-collection-debug debug backtrace
evil-collection-sh-script sh-script smie rainbow-mode rainbow-delimiters
ligature evil-collection-flymake flymake image-file image-converter
eshell-syntax-highlighting em-elecslash em-tramp em-extpipe em-glob
em-basic em-alias mule-util vertico-repeat app-launcher
evil-collection-vc-git vc-git vc-dispatcher evil-collection-consult
consult magit-bookmark evil-collection-bookmark bookmark pinentry
evil-collection-atomic-chrome atomic-chrome websocket bindat i3bar ednc
filechooser dbus exwm-xsettings xcb-xsettings exwm-background
exwm-systemtray xcb-systemtray xcb-xembed exwm-randr xcb-randr exwm
exwm-input xcb-keysyms xcb-xkb exwm-manage exwm-floating xcb-cursor
xcb-render exwm-layout exwm-workspace exwm-core xcb-ewmh xcb-icccm xcb
xcb-xproto xcb-types xcb-debug cus-start posframe face-remap
visual-fill-column org-indent evil-org ws-butler org-element org-persist
org-id org-refile avl-tree oc-basic bibtex ol-man ol-info ol-docview
evil-collection-doc-view doc-view jka-compr evil-collection-image
image-mode exif auto-compile saveplace tramp-sh savehist openwith
org-crypt org-protocol ob-http ob-http-mode org-modern executable
evil-collection-org org org-macro org-pcomplete org-list org-footnote
org-faces org-entities ob-dot ob-latex ob-python evil-collection-python
python ob-gnuplot ob-calc calc-store calc-trail calc-ext
evil-collection-calc calc calc-loaddefs calc-macs ob-shell ob ob-tangle
evil-collection-xref xref org-src ob-ref ob-lob ob-table ob-exp
ob-comint ob-emacs-lisp ob-core ob-eval org-cycle org-table ol org-fold
org-fold-core org-keys oc org-loaddefs org-compat org-version org-macs
evil-collection-notmuch notmuch notmuch-tree notmuch-jump notmuch-hello
notmuch-show notmuch-print notmuch-crypto notmuch-mua notmuch-message
notmuch-draft notmuch-maildir-fcc notmuch-address notmuch-company
notmuch-parser notmuch-wash coolj goto-addr icalendar diary-lib
diary-loaddefs evil-collection-calendar cal-menu calendar cal-loaddefs
notmuch-tag notmuch-lib notmuch-compat mm-view mml-smime smime dig
eshell-prompt-extras em-dirs em-ls em-prompt em-hist em-unix em-pred
esh-mode esh-var evil-collection-eat eat evil-collection-term term
disp-table ehelp eshell esh-cmd generator esh-ext esh-opt esh-proc
esh-io esh-arg esh-module esh-groups esh-util evil-collection-forge
forge-repos forge-topics forge-tablist hl-line forge-commands forge-semi
forge-bitbucket buck forge-gogs gogs forge-gitea gtea forge-gitlab glab
forge-github ghub-graphql treepy gsexp ghub url-http url-gw nsm url-auth
let-alist gnutls forge-notify forge-revnote forge-pullreq forge-issue
forge-topic yaml bug-reference forge-post evil-collection-markdown-mode
markdown-mode edit-indirect evil-collection-outline noutline outline
forge-repo forge forge-core forge-db closql emacsql-sqlite-common
emacsql emacsql-compiler eieio-base evil-collection-magit-todos
magit-todos pcre2el rxt re-builder f s evil-collection-grep grep
evil-collection-compile compile evil-collection-magit magit-submodule
magit-blame magit-stash magit-reflog magit-bisect magit-push magit-pull
magit-fetch magit-clone magit-remote magit-commit magit-sequence
magit-notes magit-worktree magit-tag magit-merge magit-branch
magit-reset magit-files magit-refs magit-status magit magit-repos
magit-apply magit-wip magit-log which-func evil-collection-imenu imenu
magit-diff smerge-mode diff diff-mode track-changes easy-mmode
git-commit evil-collection-log-edit log-edit message sendmail yank-media
puny dired-async dired-aux evil-collection-dired dired dired-loaddefs
rfc822 mml mml-sec evil-collection-epa epa derived epg rfc6068
epg-config gnus-util text-property-search mm-decode mm-bodies mm-encode
mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr
mailabbrev mail-utils gmm-utils mailheader pcvs-util add-log magit-core
magit-autorevert magit-margin magit-transient magit-process with-editor
server magit-mode transient magit-git magit-base
evil-collection-magit-section magit-section cursor-sensor crm recentf
tree-widget treesit-auto yasnippet async-bytecomp async sudo-edit tramp
trampver tramp-integration files-x tramp-message tramp-compat shell
pcomplete evil-collection-comint comint ansi-osc parse-time iso8601
time-date format-spec ansi-color tramp-loaddefs autorevert filenotify
project vertico corfu-popupinfo evil-collection-corfu corfu orderless
isearch-mb pixel-scroll cua-base hl-todo all-the-icons-completion
all-the-icons all-the-icons-faces all-the-icons-data-material-icons
all-the-icons-data-fluentui-system-icons
all-the-icons-data-fontawesome-4 all-the-icons-data-weather-icons
all-the-icons-data-vscode-codicons all-the-icons-data-octicons
all-the-icons-data-mfixx all-the-icons-data-file-icons
all-the-icons-data-devopicons all-the-icons-data-alltheicons svg dom xml
marginalia page-break-lines anzu modus-vivendi-theme modus-themes jinx
evil-goggles pulse color evil-textobj-tree-sitter
evil-textobj-tree-sitter-thing-at-point evil-textobj-tree-sitter-core
treesit evil-args evil-surround evil-collection-unimpaired
evil-collection-tabulated-list evil-collection-tab-bar
evil-collection-simple evil-collection-replace
evil-collection-process-menu evil-collection-package-menu
evil-collection-kmacro evil-collection-info evil-collection-indent
evil-collection-help evil-collection-elisp-mode evil-collection-eldoc
evil-collection-custom evil-collection-buff-menu evil-collection
annalist evil evil-integration evil-maps evil-commands evil-digraphs
pcase reveal evil-jumps evil-command-window evil-types evil-search
evil-ex evil-macros evil-repeat evil-states evil-core comp-run advice
evil-common thingatpt rect evil-vars ring edmacro kmacro general dash
mode-local find-func no-littering compat finder-inf notmuch-version info
all-the-icons-completion-autoloads all-the-icons-dired-autoloads
all-the-icons-ibuffer-autoloads all-the-icons-autoloads
app-launcher-autoloads aria2-autoloads atomic-chrome-autoloads
auto-compile-autoloads bash-completion-autoloads bluetooth-autoloads
buffer-move-autoloads calibre-autoloads cape-autoloads casual-autoloads
casual-dired-autoloads clojure-mode-autoloads consult-eglot-autoloads
consult-project-extra-autoloads consult-autoloads corfu-autoloads
csv-mode-autoloads dape-autoloads devdocs-autoloads
dired-filter-autoloads dired-hacks-utils-autoloads dired-k-autoloads
discomfort-autoloads debase-autoloads disk-usage-autoloads eat-autoloads
edit-indirect-autoloads ednc-autoloads eff-autoloads ellama-autoloads
ement-autoloads eshell-prompt-extras-autoloads
eshell-syntax-highlighting-autoloads eshell-vterm-autoloads
evil-anzu-autoloads anzu-autoloads evil-args-autoloads
evil-collection-autoloads annalist-autoloads evil-goggles-autoloads
evil-nerd-commenter-autoloads evil-org-autoloads evil-surround-autoloads
evil-autoloads evil-textobj-tree-sitter-autoloads evm-mode-autoloads
expand-region-autoloads exwm-autoloads filechooser-autoloads
flymake-ruff-autoloads general-autoloads git-link-autoloads
git-modes-autoloads gnuplot-autoloads goto-chg-autoloads
graphviz-dot-mode-autoloads helpful-autoloads elisp-refs-autoloads
htmlize-autoloads i3bar-autoloads igist-autoloads info-colors-autoloads
isearch-mb-autoloads iwindow-autoloads jinx-autoloads
journalctl-autoloads kotlin-mode-autoloads ligature-autoloads
link-hint-autoloads avy-autoloads llm-autoloads magit-todos-autoloads
hl-todo-autoloads marginalia-autoloads mastodon-autoloads
microdata-autoloads modus-themes-autoloads named-pipe-autoloads
nftables-mode-autoloads no-littering-autoloads
notmuch-transient-autoloads nov-autoloads esxml-autoloads kv-autoloads
ob-async-autoloads ob-http-autoloads ol-notmuch-autoloads
notmuch-autoloads openwith-autoloads orderless-autoloads
org-download-autoloads async-autoloads org-modern-autoloads
org-ql-autoloads f-autoloads org-super-agenda-autoloads
orgit-forge-autoloads orgit-autoloads forge-autoloads
markdown-mode-autoloads magit-autoloads git-commit-autoloads
ghub-autoloads closql-autoloads emacsql-autoloads ov-autoloads
ox-pandoc-autoloads ht-autoloads org-autoloads
package-lint-flymake-autoloads package-lint-autoloads
page-break-lines-autoloads password-store-autoloads pcre2el-autoloads
pdf-tools-autoloads persist-autoloads pinentry-autoloads
pkgbuild-mode-autoloads playerctl-autoloads plz-autoloads
posframe-autoloads proced-narrow-autoloads protobuf-mode-autoloads
pulseaudio-control-autoloads python-vterm-autoloads qrencode-autoloads
rainbow-delimiters-autoloads rainbow-mode-autoloads request-autoloads
rg-autoloads rmsbolt-autoloads rust-playground-autoloads
solidity-mode-autoloads spinner-autoloads ssh-config-mode-autoloads
sudo-edit-autoloads svg-lib-autoloads systemctl-autoloads
systemd-autoloads tablist-autoloads taxy-magit-section-autoloads
taxy-autoloads magit-section-autoloads tmr-autoloads transient-autoloads
treepy-autoloads treesit-auto-autoloads ts-autoloads s-autoloads
dash-autoloads tzc-autoloads udev-mode-autoloads vala-mode-autoloads
cc-styles cc-align cc-engine cc-vars cc-defs vertico-autoloads
vimrc-mode-autoloads visual-fill-column-autoloads vterm-autoloads
vundo-autoloads wat-ts-mode-autoloads watch-autoloads web-mode-autoloads
websocket-autoloads wgrep-autoloads whisper-autoloads
with-editor-autoloads wordnut-autoloads ws-butler-autoloads
xelb-autoloads yaml-autoloads yasnippet-autoloads comp comp-cstr
cl-extra help-mode comp-common warnings rx xdg package browse-url url
url-proxy url-privacy url-expand url-methods url-history url-cookie
generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse
auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x
map byte-opt gv bytecomp byte-compile url-vars cus-edit pp cus-load
icons wid-edit cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc
paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode
mwheel term/x-win x-win term/common-win x-dnd touch-screen tool-bar dnd
fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow
isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax
font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic
indonesian philippine cham georgian utf-8-lang misc-lang vietnamese
tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek
romanian slovak czech european ethiopic indian cyrillic chinese
composite emoji-zwj charscript charprop case-table epa-hook
jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs
theme-loaddefs faces cus-face macroexp files window text-properties
overlay sha1 md5 base64 format env code-pages mule custom widget keymap
hashtable-print-readable backquote threads dbusbind inotify lcms2
dynamic-setting system-font-setting font-render-setting cairo xinput2 x
multi-tty move-toolbar make-network-process native-compile emacs)

Memory information:
((conses 16 2207545 1585426) (symbols 48 98662 760) (strings 32 550071 94047)
 (string-bytes 1 16074515) (vectors 16 192171) (vector-slots 8 3258303 1326008)
 (floats 8 1044 17412) (intervals 56 69237 14428) (buffers 992 84))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Mon, 13 May 2024 22:26:01 GMT) Full text and rfc822 format available.

Message #8 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: 70927 <at> debbugs.gnu.org
Subject: Re: bug#70927: Acknowledgement (30.0.50; track-changes assertion
 when shutting down eglot)
Date: Mon, 13 May 2024 15:25:21 -0700
A quick fix would be to change `eglot--signal-textDocument/didChange`:

- from: `(eglot--track-changes-fetch eglot--track-changes)`
- to: `(when eglot--track-changes (eglot--track-changes-fetch eglot--track-changes))`

But I'm guessing there's some underlying problem and this may be masking
the real issue.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Tue, 14 May 2024 06:15:02 GMT) Full text and rfc822 format available.

Message #11 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Steven Allen <steven <at> stebalien.com>,
 Stefan Monnier <monnier <at> iro.umontreal.ca>,
 João Távora <joaotavora <at> gmail.com>
Cc: 70927 <at> debbugs.gnu.org
Subject: Re: bug#70927: 30.0.50;
 track-changes assertion when shutting down eglot
Date: Tue, 14 May 2024 09:14:18 +0300
> Date: Mon, 13 May 2024 15:21:37 -0700
> From:  Steven Allen via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> 
> 
> When `eglot-autoshutdown` is set, killing eglot buffers fails with a
> track-changes assertion because, from what I can tell,
> `eglot--signal-textDocument/didChange` is called when
> `eglot--track-changes` is `nil`.
> 
> Backtrace:
> 
>   cl--assertion-failed((memq id track-changes--trackers))
>   track-changes-fetch(nil #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_136>)
>   eglot--track-changes-fetch(nil)
>   eglot--signal-textDocument/didChange()
>   eglot--request(#<eglot-lsp-server eglot-lsp-server-10d3578e408f> :shutdown nil :timeout 1.5)
>   eglot-shutdown(#<eglot-lsp-server eglot-lsp-server-10d3578e408f>)
>   eglot--managed-mode(-1)
>   eglot--managed-mode-off()
>   kill-current-buffer()
>   funcall-interactively(kill-current-buffer)
>   command-execute(kill-current-buffer)
> 
> Reproduction:
> 
> 1. Start emacs with `emacs -Q`.
> 2. Run `M-: (setopt eglot-autoshutdown t) RET`
> 3. Open any file you have an LSP server for and run `M-x eglot RET`.
> 4. Kill the buffer.

Thanks, I added Stefan and João to the discussion.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Tue, 14 May 2024 09:16:02 GMT) Full text and rfc822 format available.

Message #14 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: Michael Albinus <michael.albinus <at> gmx.de>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 70927 <at> debbugs.gnu.org,
 João Távora <joaotavora <at> gmail.com>,
 Steven Allen <steven <at> stebalien.com>, Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: Re: bug#70927: 30.0.50; track-changes assertion when shutting down
 eglot
Date: Tue, 14 May 2024 11:14:42 +0200
Eli Zaretskii <eliz <at> gnu.org> writes:

Hi,

>> When `eglot-autoshutdown` is set, killing eglot buffers fails with a
>> track-changes assertion because, from what I can tell,
>> `eglot--signal-textDocument/didChange` is called when
>> `eglot--track-changes` is `nil`.
>> 
>> Backtrace:
>> 
>>   cl--assertion-failed((memq id track-changes--trackers))
>>   track-changes-fetch(nil #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_136>)
>>   eglot--track-changes-fetch(nil)
>>   eglot--signal-textDocument/didChange()
>>   eglot--request(#<eglot-lsp-server eglot-lsp-server-10d3578e408f> :shutdown nil :timeout 1.5)
>>   eglot-shutdown(#<eglot-lsp-server eglot-lsp-server-10d3578e408f>)
>>   eglot--managed-mode(-1)
>>   eglot--managed-mode-off()
>>   kill-current-buffer()
>>   funcall-interactively(kill-current-buffer)
>>   command-execute(kill-current-buffer)
>> 
>> Reproduction:
>> 
>> 1. Start emacs with `emacs -Q`.
>> 2. Run `M-: (setopt eglot-autoshutdown t) RET`
>> 3. Open any file you have an LSP server for and run `M-x eglot RET`.
>> 4. Kill the buffer.
>
> Thanks, I added Stefan and João to the discussion.

Btw, the corresponding (?) test fails as well:

--8<---------------cut here---------------start------------->8---
# make -C test eglot-tests
Test eglot-test-auto-shutdown backtrace:
  set-buffer(#<killed buffer>)
  (save-current-buffer (set-buffer buffer) (buffer-string))
  (princ (save-current-buffer (set-buffer buffer) (buffer-string)) 'ex
  (let ((buffer (car tail))) (eglot--test-message "contents of `%s':" 
  (while tail (let ((buffer (car tail))) (eglot--test-message "content
  (let ((tail buffers)) (while tail (let ((buffer (car tail))) (eglot-
  (cond (noninteractive (let ((tail buffers)) (while tail (let ((buffe
  (let ((buffers (delq nil (list (process-buffer (jsonrpc--process ser
  (progn (let ((buffers (delq nil (list (process-buffer (jsonrpc--proc
  (if (not test-body-successful-p) (progn (let ((buffers (delq nil (li
  (let ((server (car tail))) (if (jsonrpc-running-p server) (progn (co
  (while tail (let ((server (car tail))) (if (jsonrpc-running-p server
  (let ((tail new-servers)) (while tail (let ((server (car tail))) (if
  (let ((eglot-autoreconnect nil)) (let ((tail new-servers)) (while ta
  (unwind-protect (let ((eglot-autoreconnect nil)) (let ((tail new-ser
  (unwind-protect (let ((process-environment (cons (format "XDG_CONFIG
  (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture-" t
  eglot--call-with-fixture((("project" ("thingy.c" . "int main() {retu
  (let (server buffer) (eglot--call-with-fixture '(("project" ("thingy
  #f(lambda () [typescript-mode-abbrev-table typescript-mode-syntax-ta
  #f(compiled-function () #<bytecode 0xe07b6c3d31b780b>)()
  handler-bind-1(#f(compiled-function () #<bytecode 0xe07b6c3d31b780b>
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name eglot-test-auto-shutdown :documentati
  ert-run-or-rerun-test(#s(ert--stats :selector ... :tests ... :test-m
  ert-run-tests((not (tag :unstable)) #f(compiled-function (event-type
  ert-run-tests-batch((not (tag :unstable)))
  ert-run-tests-batch-and-exit((not (tag :unstable)))
  eval((ert-run-tests-batch-and-exit '(not (tag :unstable))) t)
  command-line-1(("-L" ":." "-l" "ert" "--eval" "(setq treesit-extra-l
  command-line()
  normal-top-level()
Test eglot-test-auto-shutdown condition:
    (error "Selecting deleted buffer")
   FAILED   3/49  eglot-test-auto-shutdown (0.229999 sec) at lisp/progmodes/eglot-tests.el:344
--8<---------------cut here---------------end--------------->8---

Best regards, Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Tue, 14 May 2024 09:36:02 GMT) Full text and rfc822 format available.

Message #17 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: João Távora <joaotavora <at> gmail.com>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: 70927 <at> debbugs.gnu.org, Eli Zaretskii <eliz <at> gnu.org>,
 Steven Allen <steven <at> stebalien.com>, Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: Re: bug#70927: 30.0.50;
 track-changes assertion when shutting down eglot
Date: Tue, 14 May 2024 10:34:29 +0100
This test passes locally (d8d4fd8c6dbe11542432fccdc31701da9f686460)
and all tests were passing recently, so this seems to be a bisectable
regression.

I ask authors that have touched eglot.el recently to run the test suite
to track this down.

João

On Tue, May 14, 2024 at 10:14 AM Michael Albinus <michael.albinus <at> gmx.de> wrote:
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> Hi,
>
> >> When `eglot-autoshutdown` is set, killing eglot buffers fails with a
> >> track-changes assertion because, from what I can tell,
> >> `eglot--signal-textDocument/didChange` is called when
> >> `eglot--track-changes` is `nil`.
> >>
> >> Backtrace:
> >>
> >>   cl--assertion-failed((memq id track-changes--trackers))
> >>   track-changes-fetch(nil #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_136>)
> >>   eglot--track-changes-fetch(nil)
> >>   eglot--signal-textDocument/didChange()
> >>   eglot--request(#<eglot-lsp-server eglot-lsp-server-10d3578e408f> :shutdown nil :timeout 1.5)
> >>   eglot-shutdown(#<eglot-lsp-server eglot-lsp-server-10d3578e408f>)
> >>   eglot--managed-mode(-1)
> >>   eglot--managed-mode-off()
> >>   kill-current-buffer()
> >>   funcall-interactively(kill-current-buffer)
> >>   command-execute(kill-current-buffer)
> >>
> >> Reproduction:
> >>
> >> 1. Start emacs with `emacs -Q`.
> >> 2. Run `M-: (setopt eglot-autoshutdown t) RET`
> >> 3. Open any file you have an LSP server for and run `M-x eglot RET`.
> >> 4. Kill the buffer.
> >
> > Thanks, I added Stefan and João to the discussion.
>
> Btw, the corresponding (?) test fails as well:
>
> --8<---------------cut here---------------start------------->8---
> # make -C test eglot-tests
> Test eglot-test-auto-shutdown backtrace:
>   set-buffer(#<killed buffer>)
>   (save-current-buffer (set-buffer buffer) (buffer-string))
>   (princ (save-current-buffer (set-buffer buffer) (buffer-string)) 'ex
>   (let ((buffer (car tail))) (eglot--test-message "contents of `%s':"
>   (while tail (let ((buffer (car tail))) (eglot--test-message "content
>   (let ((tail buffers)) (while tail (let ((buffer (car tail))) (eglot-
>   (cond (noninteractive (let ((tail buffers)) (while tail (let ((buffe
>   (let ((buffers (delq nil (list (process-buffer (jsonrpc--process ser
>   (progn (let ((buffers (delq nil (list (process-buffer (jsonrpc--proc
>   (if (not test-body-successful-p) (progn (let ((buffers (delq nil (li
>   (let ((server (car tail))) (if (jsonrpc-running-p server) (progn (co
>   (while tail (let ((server (car tail))) (if (jsonrpc-running-p server
>   (let ((tail new-servers)) (while tail (let ((server (car tail))) (if
>   (let ((eglot-autoreconnect nil)) (let ((tail new-servers)) (while ta
>   (unwind-protect (let ((eglot-autoreconnect nil)) (let ((tail new-ser
>   (unwind-protect (let ((process-environment (cons (format "XDG_CONFIG
>   (let* ((fixture-directory (make-nearby-temp-file "eglot--fixture-" t
>   eglot--call-with-fixture((("project" ("thingy.c" . "int main() {retu
>   (let (server buffer) (eglot--call-with-fixture '(("project" ("thingy
>   #f(lambda () [typescript-mode-abbrev-table typescript-mode-syntax-ta
>   #f(compiled-function () #<bytecode 0xe07b6c3d31b780b>)()
>   handler-bind-1(#f(compiled-function () #<bytecode 0xe07b6c3d31b780b>
>   ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
>   ert-run-test(#s(ert-test :name eglot-test-auto-shutdown :documentati
>   ert-run-or-rerun-test(#s(ert--stats :selector ... :tests ... :test-m
>   ert-run-tests((not (tag :unstable)) #f(compiled-function (event-type
>   ert-run-tests-batch((not (tag :unstable)))
>   ert-run-tests-batch-and-exit((not (tag :unstable)))
>   eval((ert-run-tests-batch-and-exit '(not (tag :unstable))) t)
>   command-line-1(("-L" ":." "-l" "ert" "--eval" "(setq treesit-extra-l
>   command-line()
>   normal-top-level()
> Test eglot-test-auto-shutdown condition:
>     (error "Selecting deleted buffer")
>    FAILED   3/49  eglot-test-auto-shutdown (0.229999 sec) at lisp/progmodes/eglot-tests.el:344
> --8<---------------cut here---------------end--------------->8---
>
> Best regards, Michael.



-- 
João Távora




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Wed, 15 May 2024 18:51:02 GMT) Full text and rfc822 format available.

Message #20 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Steven Allen <steven <at> stebalien.com>
Cc: 70927 <at> debbugs.gnu.org
Subject: Re: bug#70927: Acknowledgement (30.0.50; track-changes assertion
 when shutting down eglot)
Date: Wed, 15 May 2024 14:49:59 -0400
> A quick fix would be to change `eglot--signal-textDocument/didChange`:
>
> - from: `(eglot--track-changes-fetch eglot--track-changes)`
> - to: `(when eglot--track-changes (eglot--track-changes-fetch eglot--track-changes))`
>
> But I'm guessing there's some underlying problem and this may be masking
> the real issue.

Indeed.  I pushed the patch below to `master` instead which should also
fix the problem.  Please confirm that it fixes it for you as well.
Maybe `eglot-shutdown` shouldn't end up calling
`eglot--signal-textDocument/didChange` at all, but that's a long
standing behavior AFAICT, so I'll leave it for some other time.


        Stefan


diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
index 57a019e126d..0ba69f66f0d 100644
--- a/lisp/progmodes/eglot.el
+++ b/lisp/progmodes/eglot.el
@@ -2022,9 +2022,6 @@ eglot--managed-mode
       (eldoc-mode 1))
     (cl-pushnew (current-buffer) (eglot--managed-buffers (eglot-current-server))))
    (t
-    (when eglot--track-changes
-      (track-changes-unregister eglot--track-changes)
-      (setq eglot--track-changes nil))
     (remove-hook 'kill-buffer-hook #'eglot--managed-mode-off t)
     (remove-hook 'kill-buffer-hook #'eglot--signal-textDocument/didClose t)
     (remove-hook 'before-revert-hook #'eglot--signal-textDocument/didClose t)
@@ -2053,7 +2050,10 @@ eglot--managed-mode
               (delq (current-buffer) (eglot--managed-buffers server)))
         (when (and eglot-autoshutdown
                    (null (eglot--managed-buffers server)))
-          (eglot-shutdown server)))))))
+          (eglot-shutdown server))))
+    (when eglot--track-changes
+      (track-changes-unregister eglot--track-changes)
+      (setq eglot--track-changes nil)))))
 
 (defun eglot--managed-mode-off ()
   "Turn off `eglot--managed-mode' unconditionally."





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#70927; Package emacs. (Wed, 15 May 2024 20:52:01 GMT) Full text and rfc822 format available.

Message #23 received at 70927 <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 70927 <at> debbugs.gnu.org
Subject: Re: bug#70927: Acknowledgement (30.0.50; track-changes assertion
 when shutting down eglot)
Date: Wed, 15 May 2024 13:51:07 -0700
Stefan Monnier <monnier <at> iro.umontreal.ca> writes:
> Indeed.  I pushed the patch below to `master` instead which should also
> fix the problem.  Please confirm that it fixes it for you as well.
> Maybe `eglot-shutdown` shouldn't end up calling
> `eglot--signal-textDocument/didChange` at all, but that's a long
> standing behavior AFAICT, so I'll leave it for some other time.

The fix works for me. Thanks!




Reply sent to Stefan Monnier <monnier <at> iro.umontreal.ca>:
You have taken responsibility. (Wed, 15 May 2024 22:10:02 GMT) Full text and rfc822 format available.

Notification sent to Steven Allen <steven <at> stebalien.com>:
bug acknowledged by developer. (Wed, 15 May 2024 22:10:02 GMT) Full text and rfc822 format available.

Message #28 received at 70927-done <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Steven Allen <steven <at> stebalien.com>
Cc: 70927-done <at> debbugs.gnu.org
Subject: Re: bug#70927: Acknowledgement (30.0.50; track-changes assertion
 when shutting down eglot)
Date: Wed, 15 May 2024 18:09:37 -0400
>> Indeed.  I pushed the patch below to `master` instead which should also
>> fix the problem.  Please confirm that it fixes it for you as well.
>> Maybe `eglot-shutdown` shouldn't end up calling
>> `eglot--signal-textDocument/didChange` at all, but that's a long
>> standing behavior AFAICT, so I'll leave it for some other time.
> The fix works for me. Thanks!

Thanks, closing,


        Stefan





This bug report was last modified 16 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.