Alexei Srour <[email protected]> writes: > Hello Michael,
Hi Alexei, > Notably, enabling the option `tramp-debug-to-file` did not actually > change anything? I attempted adjusting variables > `tramp-compat-temporary-file-directory` and `temporary-file-directory > ` but no result. Inspecting traces of various connections always had > the `temp-file` pointing at > `C:/Users/name/AppData/Local/Temp/tramp.xxxxxx`, but I was never able > to find the file. I'll disregard the issue for the time being. Good catch! The file shall have a name like "c:/Users/albinus/AppData/Local/Temp/*debug tramp scpx albinus@gandalf*". Apparently, on MS Windows it doesn't work if a file name has a leading or trailing "*". I've fixed this in tramp-message (see appended patch); will also be fixed in the upcoming Tramp 2.8.0.5. > Inevitably, at some point today after hours of debugging and > documenting, Tramp began cooperating and creating a debug buffer for > my failed connections, no `temp-file` required. Hmm, this looks strange: --8<---------------cut here---------------start------------->8--- > 14:36:32.794272 tramp-send-command (6) # ssh -l <user> -p <port> -e none -t > -t -o RemoteCommand="/bin/sh -i" -o SetEnv="TERM=dumb" <ip address> && exit > || exit > 14:37:30.478478 tramp-accept-process-output (10) # #<process *tramp/scpx > <user>@<ip address>#<port>*> run nil > ssh -l <user> -p <port> -e none -t -t -o RemoteCommand="/bin/sh -i" -o > SetEnv="TERM=dumb" <ip address> && exit || exit > 14:37:30.482824 tramp-process-actions (3) # Waiting for prompts from remote > shell...failed > 14:37:30.483496 tramp-maybe-open-connection (3) # Opening connection for > <user>@<ip address>#<port> using scpx...failed --8<---------------cut here---------------end--------------->8--- Tramp did wait for ~1 minute, but there's no output from ssh at all. Hmm. Which ssh client do you use? Call 'ssh -V'. IIRC, older ssh clients ceased to work on MS Windows. > Kind regards, > Alexei Best regards, Michael.
diff --git a/lisp/tramp-message.el b/lisp/tramp-message.el index aafceaf3..05598bb4 100644 --- a/lisp/tramp-message.el +++ b/lisp/tramp-message.el @@ -197,9 +197,13 @@ They are completed by `M-x TAB' only in Tramp debug buffers." (defun tramp-get-debug-file-name (vec) "Get the debug file name for VEC." (declare (tramp-suppress-trace t)) - (expand-file-name - (string-replace "/" " " (tramp-debug-buffer-name vec)) - tramp-compat-temporary-file-directory)) + (let ((buffer-name (tramp-debug-buffer-name vec))) + (expand-file-name + (string-replace + "/" " " + (if (eq system-type 'windows-nt) + (substring buffer-name 1 (1- (length buffer-name))) buffer-name)) + tramp-compat-temporary-file-directory))) (defun tramp-trace-buffer-name (vec) "A name for the trace buffer for VEC."
