Subject: Re: bug#75314: 28.2; tramp-error: Invalid function: "with-tramp-connection-property"

From: Michael Albinus <[email-masked]>
Date: Fri, 03 Jan 2025 15:07:27 +0100

Jason Williams <[email-masked]> writes:

Hi Jason,

> Tramp is failing to do anything and has worked in the past on different
> installations.
>
> When I attempt to use M-x find-file /ssh:name@host: ENT it will fault
> with
>
> tramp-error: Invalid function: "with-tramp-connection-property"
>
> without fail. invoking M-x find-file /doas: ENT has no response and
> treats the input 'doas:' as a literal file.
>
> My config looks like this:
>
> (use-package tramp :straight t)
> (require 'tramp)
> (add-to-list 'tramp-connection-properties
>              (list (regexp-quote "/ssh:[email-masked]:")
>                    "remote-shell" "/bin/bashsh"))

I don't know how trustworthy an installation with straight is. But in
fact, you have an inconsistent Tramp installation.

> Load-path shadows:
> /home/jason/.config/emacs/straight/build/tramp/trampver hides
> /usr/share/emacs/28.2/lisp/net/trampver
> /home/jason/.config/emacs/straight/build/tramp/tramp hides
> /usr/share/emacs/28.2/lisp/net/tramp
> /home/jason/.config/emacs/straight/build/tramp/tramp-uu hides
> /usr/share/emacs/28.2/lisp/net/tramp-uu
> /home/jason/.config/emacs/straight/build/tramp/tramp-sudoedit hides
> /usr/share/emacs/28.2/lisp/net/tramp-sudoedit
> /home/jason/.config/emacs/straight/build/tramp/tramp-sshfs hides
> /usr/share/emacs/28.2/lisp/net/tramp-sshfs
> /home/jason/.config/emacs/straight/build/tramp/tramp-smb hides
> /usr/share/emacs/28.2/lisp/net/tramp-smb
> /home/jason/.config/emacs/straight/build/tramp/tramp-sh hides
> /usr/share/emacs/28.2/lisp/net/tramp-sh
> /home/jason/.config/emacs/straight/build/tramp/tramp-rclone hides
> /usr/share/emacs/28.2/lisp/net/tramp-rclone
> /home/jason/.config/emacs/straight/build/tramp/tramp-integration hides
> /usr/share/emacs/28.2/lisp/net/tramp-integration
> /home/jason/.config/emacs/straight/build/tramp/tramp-gvfs hides
> /usr/share/emacs/28.2/lisp/net/tramp-gvfs
> /home/jason/.config/emacs/straight/build/tramp/tramp-fuse hides
> /usr/share/emacs/28.2/lisp/net/tramp-fuse
> /home/jason/.config/emacs/straight/build/tramp/tramp-ftp hides
> /usr/share/emacs/28.2/lisp/net/tramp-ftp
> /home/jason/.config/emacs/straight/build/tramp/tramp-crypt hides
> /usr/share/emacs/28.2/lisp/net/tramp-crypt
> /home/jason/.config/emacs/straight/build/tramp/tramp-compat hides
> /usr/share/emacs/28.2/lisp/net/tramp-compat
> /home/jason/.config/emacs/straight/build/tramp/tramp-cmds hides
> /usr/share/emacs/28.2/lisp/net/tramp-cmds
> /home/jason/.config/emacs/straight/build/tramp/tramp-cache hides
> /usr/share/emacs/28.2/lisp/net/tramp-cache
> /home/jason/.config/emacs/straight/build/tramp/tramp-archive hides
> /usr/share/emacs/28.2/lisp/net/tramp-archive
> /home/jason/.config/emacs/straight/build/tramp/tramp-adb hides
> /usr/share/emacs/28.2/lisp/net/tramp-adb

It doesn't tell us which Tramp version you have installed. But at least
tramp-loaddefs isn't mentioned, which shall also have a shadow file in
your straight directory.

Best regards, Michael.