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#64278: 29.0.92; tramp-rclone.el seems to be in a defunct state Date: Sun, 25 Jun 2023 14:55:59 +0200 Message-ID: <87sfafu2e8.fsf@gmx.de> References: <87leg8kxrx.fsf@whxvd.name> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26764"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 64278@debbugs.gnu.org To: Sebastian Miele Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Jun 25 14:57:11 2023 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 1qDPIk-0006m6-QB for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 25 Jun 2023 14:57:10 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qDPIc-0002It-N2; Sun, 25 Jun 2023 08:57:02 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qDPIb-0002Ii-Bi for bug-gnu-emacs@gnu.org; Sun, 25 Jun 2023 08:57:01 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qDPIb-0003q1-2x for bug-gnu-emacs@gnu.org; Sun, 25 Jun 2023 08:57:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qDPIa-0007l9-Uy for bug-gnu-emacs@gnu.org; Sun, 25 Jun 2023 08:57:00 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jun 2023 12:57:00 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64278 X-GNU-PR-Package: emacs Original-Received: via spool by 64278-submit@debbugs.gnu.org id=B64278.168769777029751 (code B ref 64278); Sun, 25 Jun 2023 12:57:00 +0000 Original-Received: (at 64278) by debbugs.gnu.org; 25 Jun 2023 12:56:10 +0000 Original-Received: from localhost ([127.0.0.1]:42161 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qDPHl-0007jm-Tm for submit@debbugs.gnu.org; Sun, 25 Jun 2023 08:56:10 -0400 Original-Received: from mout.gmx.net ([212.227.17.22]:53825) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qDPHi-0007jA-Mc for 64278@debbugs.gnu.org; Sun, 25 Jun 2023 08:56:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1687697760; x=1688302560; i=michael.albinus@gmx.de; bh=hqitGQ4EuZHcyey/QMLjEXTp0PfRd3ajZVwwcIzOHkw=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date; b=W4uAWKDHmQO67RjlbIjycnjvoNFmk42Rz/UJjCllwns53SypnMsLuKXptmeUG6Rcw4FZ41y e2hKCAsZxAOJiIPZfN+720XhIQZ2iPQ88ZPDINgteZY1ZyizMbUSgt+rvxZygxN5hOtmtGwoP /QTujN11pErMm5fJ6Iwf/XjbpRK7tuVnTbWYhzZiSAyS0OST0nne6byo4GrABgUtUUQ+IW4mI eT/sNUZKKN+SO4b5KKftX8Gmuu1tTnglua3Ke9O81JhfClT2GQinUufPBdmTsf7rbtDQvuDO/ OluY9ZqMea1QgrzXkQNxvCsNpXOJJHdvYFQiiDTjqqd/1BwS+jLw== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from gandalf.gmx.de ([185.89.39.13]) by mail.gmx.net (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MTzb8-1qeOJe301y-00Qwuk; Sun, 25 Jun 2023 14:56:00 +0200 In-Reply-To: <87leg8kxrx.fsf@whxvd.name> (Sebastian Miele's message of "Sun, 25 Jun 2023 05:16:32 +0200") X-Provags-ID: V03:K1:n0xlgZYgvykWQ2SZtlTGhIEkbHYQxH2sm2ZOz8vp5j3zO++KpND LRHf+1xtMZBO2exq3uv0nPX/2lo1mBiPIWgglddCCAK+vDuBZrFKheTiDLF/0E3Gk7zSwWW KGW/53E/VlZoeStHK7783pKySjcL3iCjyG2EkUOT7wRpWsL+kR8vBEXtoieAZsOS9QNKrZw ETccIS6KTTASXw10qS5BA== UI-OutboundReport: notjunk:1;M01:P0:eZLEFypo/ac=;+vp1E0hbWr9YLIxogW/2d/KCHKN fJfERBrvWblsxkuGTnBkS1pxYXByef6BbtAWXUF/8qSTteJpNI5JJldJzQCqOZLRhBFc7aWJw JMmX6/och9WQUjCZW5v8+M+p2E+A+Vq8h+KU/wAye0UerupJPbb6L6KLakxtIJ2V8ppkGL1es FaGWdChJ/vwqHN//Cj7S2eQx0PZ07kY3I5LMFQLrnYvxZ797rHLIXHVR72iW+NrJghzSxgDAj C0ri6GSiTNX50eJ2yweRKazgnTbzQElAOgy5fSE+d1OkbDnpDuP+HzJE3O8xpnuyoCedTocGQ zOrnCr52x4PtzzBryTByYdGvNpM7p3wXHK3OweNHc/NloBzM2j7FamtHQFEGx+4CXvvGiz6uv GzJ612RHjpbdpSFp2sqvPBX++nVCtsHfYBpN8JV6Oms2ZDXIaThsjzavMmi8Rz41CFrA3IhmO KYBg3X9lvLYkHPwEL6HvDty2WmVo4TyOzsCGbQy5JYWX1cQqMK9SjMey5WMyxk7rPODrk9bjm NjxUpEHDdBwL3P/fToe4L8+g3AWBuE9SjfAs98guwiMo8kE8lf/XIzcTly8oc+QtUY6JniwNx wDdp5W9HtqX1VP4G1vMMIzWxD+j1fo2XhUfK343lK3006tOXySnA/floYHHEo3N1qj42ekYLw HJkwUy+xG97SHpRmWS3ggHys6ZtI4dXXWIgeYC6lRxzy9IKK6B2ZjDTstW/qS+lMMSLMDeXBw 9/Jkfy1eTBSvnUFJFgBa8Yx7BDWHF0kNxsJBtzHfaJL0IM+aDZnWrU3nwnAcJRQHJyZYzfkn 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:264041 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Sebastian Miele writes: Hi Sebastian, Thanks for the report. I've never tried the memory type of rclone. I have two test entries in ~/.config/rclone/rclone.conf: --8<---------------cut here---------------start------------->8--- [local_drive] type =3D local nounc =3D true [gdrive] type =3D drive scope =3D drive ... --8<---------------cut here---------------end--------------->8--- Both work, and they are tested regularly in my regression tests. So I wouldn't say that tramp-rclone.el is in a defunct state. > I am using the Tramp built into the most recent emacs-29 from the Emacs > repository. Steps to reproduce the first problem: > > Augment ~/.config/rclone/rclone.conf with: > > [memory] > type =3D memory > > I tried to debug the issue for myself for a while. The first issue I > encountered, is that =E2=80=98tramp-rclone=E2=80=99 contains a call to > =E2=80=98tramp-call-process=E2=80=99 with a DESTINATION of 0. =E2=80=98t= ramp-call-process=E2=80=99 > contains > > (tramp-get-buffer-string destination) > > which in that case yields an error. I tried changing "destination" in > that line into: > > (unless (eq destination 0) destination) Reproduced here. I've pushed a fix to the emacs-29 branch in git. Furthermore, there is indeed a problem detecting a mount point for rclone memory type. The appended patch should fix this. However, calling "emacs /rclone:memory:" with the rclone.conf entry given by you.conf results in in an empty directory. No file visible there, even if I copy something. I've tried the rclone memory type manually in a shell --8<---------------cut here---------------start------------->8--- # mount -t fuse.rclone local_drive:/ on /tmp/tramp.rclone.local_drive type fuse.rclone (rw,nosuid,= nodev,relatime,user_id=3D1000,group_id=3D1000) memory: on /tmp/tramp.rclone.memory type fuse.rclone (rw,nosuid,nodev,relat= ime,user_id=3D1000,group_id=3D1000) # ls -al /tmp/tramp.rclone.memory total 0 drwxr-xr-x. 1 albinus albinus 0 Jun 25 14:49 . drwxrwxrwt. 99 root root 7800 Jun 25 14:49 .. # rclone copyto ~/tmp memory: # ls -al /tmp/tramp.rclone.memory total 0 drwxr-xr-x. 1 albinus albinus 0 Jun 25 14:49 . drwxrwxrwt. 99 root root 7800 Jun 25 14:51 .. --8<---------------cut here---------------end--------------->8--- So I'm a little bit undecided what the memory type of rclone is good for, and how it works. Do I miss something? Best regards, Michael. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/lisp/net/tramp-fuse.el b/lisp/net/tramp-fuse.el index e1ad0c2e5d2..c10c715d70e 100644 =2D-- a/lisp/net/tramp-fuse.el +++ b/lisp/net/tramp-fuse.el @@ -175,13 +175,24 @@ tramp-fuse-mounted-p (or (tramp-get-file-property vec "/" "mounted") (let* ((default-directory tramp-compat-temporary-file-directory) (command (format "mount -t fuse.%s" (tramp-file-name-metho= d vec))) - (mount (shell-command-to-string command))) + (mount (shell-command-to-string command)) + (mount-spec (split-string (tramp-fuse-mount-spec vec) ":" 'omit))= ) (tramp-message vec 6 "%s\n%s" command mount) + ;; The mount-spec contains a trailing local file name part, + ;; which might not be visible, for example with rclone + ;; mounts of type "memory" or "gdrive". Make it optional. + (setq mount-spec + (if (cdr mount-spec) + (tramp-compat-rx + (literal (car mount-spec)) + ":" (? (literal (cadr mount-spec)))) + (car mount-spec))) (tramp-set-file-property vec "/" "mounted" (when (string-match (tramp-compat-rx - bol (group (literal (tramp-fuse-mount-spec vec))) blank) + bol (group (regexp mount-spec)) + " on " (group (+ (not blank))) blank) mount) (match-string 1 mount))))))) --=-=-=--