GNU bug report logs -
#37464
26.3; Icomplete and TRAMP create unnecessary buffer
Previous Next
Reported by: Andrii Kolomoiets <andreyk.mad <at> gmail.com>
Date: Thu, 19 Sep 2019 20:39:02 UTC
Severity: normal
Tags: notabug
Found in version 26.3
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
Message #18 received at 37464-done <at> debbugs.gnu.org (full text, mbox):
Andrii Kolomoiets <andreyk.mad <at> gmail.com> writes:
> Hi Michael,
Hi Andrii,
> But why this doesn't happen when icomplete-mode is disabled?
> C-x C-f /q:: <TAB> says "Method 'q' is not known" and there are
> no `*tramp/q...` buffer.
You activate icomplete-mode for a reason. Icomplete calls (file-exists-p
"/ssh:hostname:"), after you have typed "/ssh::" (given that "hostname" is
the name of your host). Without icomplete-mode, this doesn't happen.
> Let me explain how i faced this behaviour. I have some commands that do
> `(abbreviate-file-name default-directory)`. After misspelled `sudo` as
> TRAMP method in `find-file` prompt like `/suod::/etc/hosts` and
> cancelling command with `C-g` the buffer `*tramp/suod...` was created.
> And `(abbreviate-file-name default-directory)` in that buffer leads to
> "Method 'suod' is not known" error.
Yes. But why do you call it in this buffer?
> I thought that buffer `*tramp/suod...` was created mistakenly.
> If this is expected behaviour do i need to wrap `abbreviate-file-name`
> with `condition-case` or something?
(ignore-errors (abbreviate-file-name default-directory)) would do.
> Actually there are more command that won't work from the
> `*tramp/suod...` buffer: vc-dir, find-file, dired.
> All of them leads to "Method 'soud' is not known" error.
Yes, but only if you take the buffer with the damaged
default-directory. I would try to ban such a buffer in my code.
> Thanks!
Best regards, Michael.
This bug report was last modified 5 years and 238 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.