Subject: bug#57336: 29.0.50; Tramp and recentf yet again

From: Michael Albinus <[email-masked]>
Date: Mon, 29 Aug 2022 12:08:58 +0200

Stefan Kangas <[email-masked]> writes:

Hi Stefan,

>>> With my current build from master, when my ~/emacs.d/recentf file
>>> contains an entry that uses ssh to connect to another machine and this
>>> machine is offline when I start Emacs, then Tramp repeatedly tries to
>>> connect to that machine.  [...]
>>
>> I suspect that this is due to
>>
>> commit c753e4cb2a2a5998626d48d85071c047cbab6c54
>> Author: Stefan Kangas <[email-masked]>
>> Date:   Thu Jun 23 11:00:19 2022 +0200
>>
>>     Use shortened filenames in recentf-mode
>>
>>     * lisp/recentf.el (recentf-filename-handlers): Set to
>>     'abbreviate-file-name' to get shortened names by default.  (Bug#56123)
>>
>> 'abbreviate-file-name' tries to establish a connection for remote file
>> names.
>
> Hmm, maybe Michael knows what's going on here, added to Cc.

The problem is rather expand-file-name, which goes remote when the file
name contains a tilde "~". I've pushed a fix to master, could you pls
check?

Best regards, Michael.