GNU bug report logs - #19636
[TRAMP] global minor mode hangs connection when accessing files in :lighter

Previous Next

Package: emacs;

Reported by: Philippe Vaucher <philippe.vaucher <at> gmail.com>

Date: Tue, 20 Jan 2015 18:17:03 UTC

Severity: normal

Fixed in version 26.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

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#19636: closed ([TRAMP] global minor mode hangs connection
 when accessing files in :lighter)
Date: Fri, 14 Jul 2017 13:13:01 +0000
[Message part 1 (text/plain, inline)]
Your message dated Fri, 14 Jul 2017 15:12:18 +0200
with message-id <87inivp3gt.fsf <at> detlef>
and subject line Re: bug#19636: [TRAMP] global minor mode hangs connection when accessing files in :lighter
has caused the debbugs.gnu.org bug report #19636,
regarding [TRAMP] global minor mode hangs connection when accessing files in :lighter
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
19636: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=19636
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Philippe Vaucher <philippe.vaucher <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: [TRAMP] global minor mode hangs connection when accessing files in
 :lighter
Date: Tue, 20 Jan 2015 18:49:31 +0100
[Message part 3 (text/plain, inline)]
Hello,

TRAMP hangs the connection for any new processes in both emacs 24.4
and emacs from the master branch when a global minor mode uses a
:lighter which evals `(file-truename default-directory)`.

To reproduce:

M-x find-file buggy-tramp-mode.el
M-x eval-buffer
M-x global-buggy-tramp-mode
M-x find-file /scpx:user <at> host:/tmp/foo.txt
M-x async-shell-command ls

The last command (new process) doens't complete and the TRAMP buffer
shows "Are you awake?". My understanding of the problem is that
`file-truename` tries to use a not-yet-ready TRAMP connection. To work
around that was tried is to use `tramp-connectable-p` or even
`file-remote-p` with the appropriate flags, but they both
(incorrectly?) return true.

The "real world" issue that it affects is
https://github.com/bbatsov/projectile/issues/523

Please ask if I'm unclear or you need more clarifications.

Thanks,
Philippe
[buggy-tramp-mode.el (text/x-emacs-lisp, attachment)]
[Message part 5 (message/rfc822, inline)]
From: Michael Albinus <michael.albinus <at> gmx.de>
To: Philippe Vaucher <philippe.vaucher <at> gmail.com>
Cc: 19636-done <at> debbugs.gnu.org
Subject: Re: bug#19636: [TRAMP] global minor mode hangs connection when
 accessing files in :lighter
Date: Fri, 14 Jul 2017 15:12:18 +0200
Version: 26.1

Philippe Vaucher <philippe.vaucher <at> gmail.com> writes:

Hi Philippe,

>     > Basically, do nothing if there's no reliable way of getting the
>     > information yet (we are remote and not connected yet).
>
>     Sounds reasonable for me, thanks for reporting the status. I also
>     recommend to test with the development version of Emacs (aka
>     26.0.50), because there have been serious changes in Tramp.
>
> Good idea.
>
>     Well, I don't see what could be done else here on emacs-devel.
>     What do you expect us to do else?
>
> Oh, I was just reporting my findings. Not much you can do except keep
> in mind people *do* call various emacs api on buffer-file inside :
> lighter or even inside the function that has to decide wether a mode
> should be on or off, so the emacs api should be resilient to errors
> reguarding this. Currently it fails kinda catastrophically when you
> don't check with `file-remote-p` beforehand (emacs hang and one has to
> furiously press C-g or C-c to get emacs back, and often this is not
> sufficient as any command you want to type hangs again, so one has to
> quit).

I'm closing this bug, because there's nothing left to do.

Tramp 2.3.2 of Emacs 26.0.50 has seen some patches for improving
asynchronous processes. Maybe they help you.

> Philippe

Best regards, Michael.


This bug report was last modified 7 years and 308 days ago.

Previous Next


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