From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.bugs Subject: bug#55832: 28.1; Emacs crashes when using tramp from helm in emacs-29 Date: Fri, 10 Jun 2022 14:20:15 +0200 Message-ID: <87k09ohfr4.fsf@gmx.de> References: <87pmjhgdiv.fsf@gmx.de> <87edzwakji.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36807"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: Eli Zaretskii , larsi@gnus.org, 55832@debbugs.gnu.org To: Thierry Volpiatto Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jun 10 14:22:09 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nzdeT-0009KN-B7 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 10 Jun 2022 14:22:09 +0200 Original-Received: from localhost ([::1]:39510 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nzdeQ-0001BJ-V2 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 10 Jun 2022 08:22:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48948) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nzddO-0001Aa-3r for bug-gnu-emacs@gnu.org; Fri, 10 Jun 2022 08:21:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:55253) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nzddN-0004cT-S8 for bug-gnu-emacs@gnu.org; Fri, 10 Jun 2022 08:21:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nzddN-0005NR-Lm for bug-gnu-emacs@gnu.org; Fri, 10 Jun 2022 08:21:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 10 Jun 2022 12:21:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55832 X-GNU-PR-Package: emacs Original-Received: via spool by 55832-submit@debbugs.gnu.org id=B55832.165486362620613 (code B ref 55832); Fri, 10 Jun 2022 12:21:01 +0000 Original-Received: (at 55832) by debbugs.gnu.org; 10 Jun 2022 12:20:26 +0000 Original-Received: from localhost ([127.0.0.1]:49150 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nzdcn-0005MO-Pz for submit@debbugs.gnu.org; Fri, 10 Jun 2022 08:20:26 -0400 Original-Received: from mout.gmx.net ([212.227.15.15]:56929) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nzdcl-0005M8-Bw for 55832@debbugs.gnu.org; Fri, 10 Jun 2022 08:20:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1654863616; bh=HdZ5u2vdFEBo4fV7vxNyIkjfqArv5GB3MvfOmAPDZVE=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=bbNrarTpFME/cDxTvFmXMp6+N28LFR09HYZgSxLo9dhTuU2mi1ZA4BMnxCyQjAzt8 ihPhd/yCSUJqt9200ArTL5XxYXvykt2JpZIQlxx4KaPhOPzhkM4Rtv9AHga1+fVhb2 PPqGTg8WkdXq0vrRYtX7XIBY9BQ9eCghI6RUXogY= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from gandalf.gmx.de ([79.140.124.174]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MTiPv-1oBV5J0myb-00U1i3; Fri, 10 Jun 2022 14:20:16 +0200 In-Reply-To: <87edzwakji.fsf@posteo.net> (Thierry Volpiatto's message of "Fri, 10 Jun 2022 10:00:12 +0000") X-Provags-ID: V03:K1:KYQMtddh7DxKL/Cai0XHDXzFbUaMHgo2K5Ded7X+I+0LDFGf6vg 0XP8jBWY5/SVtYyEPRB5I2qlnp1OPUIH8nyuSDW3EqQRYHP5J3pZVZnu62PQkzKyXYpPkt8 WankXM7RvlTey3k7bpCo2Ok9btxY2IbcjDirsJHtho/0hX9H396Urk7poA20YWkAcQ9EFhm MxYU1r+MREJ8NFMnV/GQA== X-UI-Out-Filterresults: notjunk:1;V03:K0:OzjpXpQFq3E=:ihk2WazVYGTmfoYClenuG9 gGBWfJGYZsewwgR6DjceIyOLi6aoo8yXmQt+7uWuZHSEtyIQjM//+w94zH38HybgXk07cEyqy NiH6+IAWPAYo2/Gy7RMQDcNJQTheXJbvhCmhsJTMLSk96bN5ztCfXeiX6Bx5E1JDID8Nb3/dO /hjuxz640yv9MrbmqXe32hoDUKQORSqcv3IbEKnXl6QuyZFwpGnU4QVCapg4lI+KOBtMc2fC5 z63Y7slUZ4wNE/VYQElv+65bLzXIVS1KoQ6Hft4/oPWIejPKfGfrmzmx3j3+VpRgznf3jhvmZ 7GZ2ArdbpKFkU7anqby8JKSvWR3VlIzqBVF+TSiecDjFcOHwH3Ge2VgaBmSQGJ+zo605nZ863 oESzqe+e34RXiJ1xb0hzieoxjEhK3HyC/s7J2/YuHIu/MYyj6lHf9wZDRkr5nNZwsGRJhQDX/ sJwPj0nuagP/9iw9sMBssDKBGh/2ZsKYmIGv5clWp4gI9sODEWfwDFI2oNH7M/+EMo3DB7suS VIOZyLkNFQImVlEYR/kK3UmsHjQuVRyr5fF7pLORiWOL8oyBMkWoZppncHbr8Le8Q3e6hp8+E /qa7gCD/lt0kWf7rcNQ11ao/kB2tZJlAhZXGFHGgz+Bxe+Kjwj02cigeq1CJbj+vamxW4hSX6 7HAkffPypvcrXv/dw01pmDDFCiwi6Rv2Pv06elh8/iOf78slWC6aKiqMGdsrnvysgk+2FsCBs xP3tDVXxF4NF6LSfXhQvPNJIOcNvog4h4g37MrJ9wl5vG75XMpaez/N5FH+xynbuqDq6SJzy X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:234221 Archived-At: Thierry Volpiatto writes: > Hello Michael, Hi Thierry, >> First, I've tried to reproduce it from emacs -Q. I've upgraded all >> installed ELPA packages, and then I have called >> >> emacs -Q \ >> -l ~/.emacs.d/elpa/helm-core-20220503.622/helm-core-autoloads.el \ >> -l ~/.emacs.d/elpa/helm-20220504.827/helm-autoloads.el \ >> -l ~/.emacs.d/elpa/helm-tramp-20190616.125/helm-tramp-autoloads.el \ > > What is helm-tramp? this is not part of helm. I've installed this as ELPA package a while ago, don't remember the details. So I've taken this out, calling now Emacs master branch like emacs -Q \ -l ~/.emacs.d/elpa/helm-core-20220503.622/helm-core-autoloads.el \ -l ~/.emacs.d/elpa/helm-20220504.827/helm-autoloads.el \ -l ~/.emacs.d/elpa/async-20220318.1342/async-autoloads.el -l seq > You have better time cloning emacs-async and run make && sudo make > install and same with helm, then emacs -q, (require 'helm) (require > 'helm-config) and C-x c C-x C-f Hmm, this would poison my laptop with an undesired config. Shouldn't the call above be sufficient? >> Using /sudo:: as file name doesn't raise any error. > > Did you follow the recipe I sent? > First shot doesn't crash but second after M-x > tramp-cleanup-all-connections does. Ahh, this was another message I didn't notice. >> However, this is from the master branch; > > The bug is from master branch not emacs-28, I sent the bug report from > my main emacs which is emacs-28 because 29 crashed. OK, rerunning your recipe with the invocation as above: > 1) Ensure you have no entries for sudo in .authinfo.gpg file. Not needed, because I call "emacs -Q". > 2) M-x helm-find-files RET // sudo:: Done. > 3) You are prompted for password Yep. > 4) At this first shot it should work as expected. Not clear to me whether I shall enter the password. I did. Now Helm offers me something, which I always confirm with RET, until I see the dired buffer of "/sudo:root@gandalf:/root". "gandalf" is the name of my laptop. > 5) C-g to quit, and M-x tramp-cleanup-all-connections. Done. > 6) Restart helm-find-files and enter /sudo:: emacs should freeze and crash. I've switched to the *scratch* buffer, and did this. No problem. ----- Now a second attempt. Steps 1-3 as above. > 4) At this first shot it should work as expected. I didn't enter the password. > 5) C-g to quit, and M-x tramp-cleanup-all-connections. Done. I have applied C-g twice in order to go out of the minibuffer. > 6) Restart helm-find-files and enter /sudo:: emacs should freeze and crash. No, Emacs asks me for the /sudo:: password, and continues as expected. >> tramp-get-remote-uid *is* a valid argument, and >> tramp-file-name-for-operation shouldn't raise an error. Once we have >> fixed the problem of Emacs crash, it shall be investigated wy this error >> has been raised. > > tramp-get-remote-uid is calling tramp-file-name-handler with > tramp-get-remote-uid as arg so I guess the infinite recursion starts > here isn't it? No. tramp-get-remote-uid invokes tramp-file-name-handler in order to get a method specific implementation (finally, tramp-sh-handle-get-remote-uid shall be called). >> It is not clear to me why tramp-file-name-for-operation goes into >> recursion with the error handling, invoking again and again >> tramp-signal-hook-function (that is the function bound to >> signal-hook-function). > > What is calling tramp-get-remote-uid in tramp-file-name-for-operation? tramp-get-remote-uid should *not* be called inside tramp-file-name-for-operation. The symbol is passed as argument, and used for investigation of the other args. >> Similar protections have been applied already elsewhere in Tramp. Does >> this solve the problem? > > No still crashing. Sad. Since I cannot reproduce the problem locally, what happens if you invoke "emacs -Q" similar to how I've done? Best regards, Michael.