Subject: bug#31731: 26.1; tramp-file-name-handler: Variable binding depth exceeds max-specpdl-size

From: Marc Girod <[email-masked]>
Date: Tue, 5 Jun 2018 22:26:38 +0100

I had to reinstall a fresh emacs after an upgrade on my laptop.
$ brew reinstall emacs --with-cocoa
$ brew cask install emacs
$ brew services start emacs
$ sudo xcode-select -switch /Applications/Xcode.app
$ sudo port install emacs-app
--->  Computing dependencies for emacs-app
--->  Cleaning emacs-app
--->  Scanning binaries for linking errors
--->  No broken files found.
--->  No broken ports found.
~> xcode-select -print-path
/Applications/Xcode.app/Contents/Developer

I installed tramp from a clone of the git repo:
./configure --with-emacs=/Applications/Emacs.app/Contents/MacOS/Emacs --with-lispdir=/Library/Application/emacs/site-lisp --with-contrib

This emacs/site-lisp hierarchy was created for this purpose.

I added to .emacs:

(add-to-list 'load-path "/Library/Application/emacs/site-lisp")
(require 'tramp)

Restarted emacs, attempted to access a remote directory:

/marcgirod-wsl5:

and got the error reported below.
I notice the 'hidings' below, and I'll investigate them, but without my
addition to load-path, tramp was not found -- at least not invoked for
the above mentioned remote access.

Thanks,
Marc

In GNU Emacs 26.1 (build 1, x86_64-apple-darwin14.5.0, NS appkit-1348.17 Version 10.10.5 (Build 14F2511))
of 2018-05-31 built on builder10-10.porkrind.org
Windowing system distributor 'Apple', version 10.3.1561
Recent messages:
Error during redisplay: (ucs-normalize-hfs-nfd-pre-write-conversion 1 9) signaled (error "Variable binding depth exceeds max-specpdl-size") [2 times]
tramp-file-name-handler: Variable binding depth exceeds max-specpdl-size
Quit
C-x C-g is undefined
Quit
Mark activated

Configured using:
'configure --with-ns '--enable-locallisppath=/Library/Application
Support/Emacs/${version}/site-lisp:/Library/Application
Support/Emacs/site-lisp' --with-modules'

Configured features:
NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS MODULES THREADS

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  shell-dirtrack-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
/Library/Application/emacs/site-lisp/tramp-smb hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-smb
/Library/Application/emacs/site-lisp/tramp-uu hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-uu
/Library/Application/emacs/site-lisp/tramp hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp
/Library/Application/emacs/site-lisp/tramp-sh hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-sh
/Library/Application/emacs/site-lisp/trampver hides /Applications/Emacs.app/Contents/Resources/lisp/net/trampver
/Library/Application/emacs/site-lisp/tramp-cmds hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-cmds
/Library/Application/emacs/site-lisp/tramp-cache hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-cache
/Library/Application/emacs/site-lisp/socks hides /Applications/Emacs.app/Contents/Resources/lisp/net/socks
/Library/Application/emacs/site-lisp/tramp-compat hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-compat
/Library/Application/emacs/site-lisp/tramp-ftp hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-ftp
/Library/Application/emacs/site-lisp/tramp-loaddefs hides /Applications/Emacs.app/Contents/Resources/lisp/net/tramp-loaddefs

Features:
(shadow sort mail-extr emacsbug message rmc puny seq rfc822 mml easymenu
mml-sec epa derived epg epg-config gnus-util rmail rmail-loaddefs
mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils
mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr
mail-utils tramp-sh dired dired-loaddefs elec-pair tramp tramp-compat
auth-source cl-seq eieio byte-opt bytecomp byte-compile cconv eieio-core
cl-macs gv eieio-loaddefs cl-loaddefs cl-lib password-cache
tramp-loaddefs shell pcomplete comint ansi-color ring format-spec advice
time-date tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/ns-win ns-win ucs-normalize mule-util
term/common-win tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow isearch timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite charscript charprop case-table epa-hook jka-cmpr-hook
help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote kqueue cocoa ns multi-tty make-network-process emacs)

Memory information:
((conses 16 221438 11098)
(symbols 48 21852 1)
(miscs 40 59 135)
(strings 32 35931 1207)
(string-bytes 1 1013958)
(vectors 16 38073)
(vector-slots 8 751612 9580)
(floats 8 69 177)
(intervals 56 215 0)
(buffers 992 11))