GNU bug report logs -
#66381
29.1; Auto-revert not polling files when notifications are enabled
Previous Next
Reported by: Daniel Jacobowitz <daniel.jacobowitz <at> gmail.com>
Date: Sat, 7 Oct 2023 01:27:03 UTC
Severity: normal
Found in version 29.1
Fixed in version 30.1
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
I use a network filesystem which sometimes has to restart, e.g. for
updates or when credentials expire. Normally, file notifications work
fine on this filesystem, but after a restart the old notifications will
never fire. Documentation says "By default, Auto Revert mode will poll
files for changes periodically even when file notifications are used." -
experimentally the file is never polled.
Ideally the notification would be recreated, but falling back to
polling would be
an improvement.
Reproduce from emacs -Q:
(global-auto-revert-mode t)
Open a file on the filesystem where notifications break
Append to the file externally -> emacs notices immediately
Restart the daemon, breaking notifications
Append to the file externally -> emacs never notices
This has been broken for a while. From auto-revert-handler:
(revert
(if buffer-file-name
(and (or auto-revert-remote-files
(not (file-remote-p buffer-file-name)))
(or (not auto-revert-notify-watch-descriptor)
auto-revert-notify-modified-p)
... eventually poll
Prior to bug#20943, there was a call to buffer-modified-p at the top
level that checked unconditionally whether the file had been modified.
Build:
In GNU Emacs 29.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.37,
cairo version 1.16.0) of 2023-09-03, modified by Debian built on
kokoro-ubuntu
System Description: Debian GNU/Linux rodete
There's a bunch of local bits in our Emacs build, but I'm ~mostly sure
they are unrelated
to this bug.
--
Thanks,
Daniel
This bug report was last modified 1 year and 277 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.