Lars Ingebrigtsen <larsi@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 13 Oct 2020 11:59:49 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Oct 13 07:59:49 2020 Received: from localhost ([127.0.0.1]:45494 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kSIy5-0001Su-Co for submit <at> debbugs.gnu.org; Tue, 13 Oct 2020 07:59:49 -0400 Received: from mail-ej1-f44.google.com ([209.85.218.44]:44926) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kSIy3-0001Sc-I5 for 43464 <at> debbugs.gnu.org; Tue, 13 Oct 2020 07:59:48 -0400 Received: by mail-ej1-f44.google.com with SMTP id a3so27809109ejy.11 for <43464 <at> debbugs.gnu.org>; Tue, 13 Oct 2020 04:59:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=NVEicAF9QsZpQFP//JnHXFV1HHJep3at4QsAXLWXWAI=; b=PTH9ZQpaw2PiU7I6UbsqYSAAa70008C/nM0epuWH9csSpz1STictTZcKaNVnFjLrTC cdLIOmJJG38KiqrUlX9D7q/KJe1vddu89PKgqZ+SnVkzEBgSIVUfsJPCi9h+958v9iS3 RCs6wm3hNajXphuyow6ATC7cdFGqHkYr4wIZBSGInLmIv+Lr81Z82nQKv/ar8a4bgicT x8gnW/qxRuagra+BOJXWA426MKa+ZXCRl8lUMVFAF51Qg1dDwji9rYp1Me0rU7dsap8G K2Vj53Zs5JXgmD5vX2XGSTkEqTbas9BduHDktTvIJG51KBmIA36/N1DRsqpTD/plZWBB gpHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=NVEicAF9QsZpQFP//JnHXFV1HHJep3at4QsAXLWXWAI=; b=D3npa8xFk73dGL04AD3W3xucJbxtYpULJ3l5bbxjWcOR3xkgHXPIS4LrP0OCTHj1ba DnZUh2anOzdCMNyF6oozjQ8ivhXIzHzyjKAaQEfhVnzaBRw9UuHkdEPI/Ks8M5397+wu 1i+aWmAxTZ3vWmpe28JAYHZtdb2aoPig3pezbEXcHhUUJ1pWWSWhI73XrromsDpGX/TK kwzLiqQY0fORa4MuGf3Lus/WpQIVhSpbcAoKxqczXocIvOlrqi17HhdEQ0X/1nekHA/X riFIac22PwevJd1MR4E/L33lUTj7ogRLpm/zsAx1PhwMlByskw1c2eZ7JtQTMREo2cgE Ouxg== X-Gm-Message-State: AOAM532xEhUMEn84MqINeBg2eNvm9Mhb0/gxb1c76tmtc0tnte0hmiRv xL3qAfzW4zbxVuoAPfDeT2a+48D0flROSg== X-Google-Smtp-Source: ABdhPJzpcGx8kKJhihNm53wxEkq79Al7Tck2Ip1cAr6Tz+3Z/H2J2waQD5Ay7K0Wtqvu1Ichz46RrA== X-Received: by 2002:a17:906:3455:: with SMTP id d21mr35019210ejb.89.1602590381355; Tue, 13 Oct 2020 04:59:41 -0700 (PDT) Received: from [192.168.0.4] ([66.205.71.3]) by smtp.googlemail.com with ESMTPSA id c5sm12520010edx.58.2020.10.13.04.59.39 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 13 Oct 2020 04:59:39 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> <m24kn9i51g.fsf@HIDDEN> <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> <m2sgaquqg2.fsf@HIDDEN> <fbff5fc9-d8cb-bae4-05a7-be1822eccfd5@HIDDEN> <m2sgakld7r.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <74547795-7592-7c33-af81-326144bb0bc6@HIDDEN> Date: Tue, 13 Oct 2020 14:59:38 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m2sgakld7r.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) On 11.10.2020 23:28, Andrii Kolomoiets wrote: > Dmitry Gutov <dgutov@HIDDEN> writes: > >>> Can you please advice me what this change should look like? Get rid >>> of calling 'vc-call'? >> >> Yes. How about the attached patch? > > Small fix: THEN and ELSE blocks of the '(if dir...' should be swapped. Ah yes, thanks for noticing. > Does those kind of changes should be applied to any function that uses > 'vc-call' and can be called on dirs? I think so. Since none of them should work on directories now, it should be accompanied with some doc changes as well. > Is there any reason to use 'vc-backend' at all? > > 'vc-responsible-backend' will call 'vc-backend' on a file that is not a > directory. Well, vc-backend is certain to be faster, on average. That is one advantage. Minus one disk loopup, or minus extra network interaction with Tramp (that's where it might really hurt). I don't have a very strong argument here, except the current code works, and it should be easier to annotate the exceptions where we do want to handle directories. And while we do that, consider the performance implications for each case. >>> In this case the function 'vc-version-backup-file' >>> must be changed as well. >> >> Does it actually make sense to use it on a directory? > > Looks like it make sense for CVS backend. Take a look at > 'vc-cvs-stay-local-p'. It might be desired for CVS (to cut down on network traffic), but how would it work? The function is supposed to return a backup file name. But we don't create backup files for whole directories. Only for individual files. >> Something like that. Or 'git init' inside a subdirectory. Not a >> frequent occurrence, but if we start using directories and files >> interchangeably in more places, we are likely to start caching other >> properties on them, too. So it's better to use a different function to >> detect which backend a directory belongs to. > > In this case `vc-call` must use that function, right? No, vc-call won't be used. Like in the patch I sent previously. >> Also, your patch makes vc-registered work on directories. > > How is that? 'vc-registered' is still returns nil for directories. The > changes affects only the side effect of it. Oh, now I finally understand what it's doing. You can probably see how it's not ideal control flow (call a function, see it return nil, and then rely on its undocumented side-effect). So if we can avoid doing that and still fix the bug, the alternative approach should be preferable.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 11 Oct 2020 20:28:19 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Oct 11 16:28:19 2020 Received: from localhost ([127.0.0.1]:41125 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kRhx5-0001pe-HL for submit <at> debbugs.gnu.org; Sun, 11 Oct 2020 16:28:19 -0400 Received: from mail-lj1-f182.google.com ([209.85.208.182]:46981) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kRhx3-0001pS-Qj for 43464 <at> debbugs.gnu.org; Sun, 11 Oct 2020 16:28:18 -0400 Received: by mail-lj1-f182.google.com with SMTP id c21so14840725ljn.13 for <43464 <at> debbugs.gnu.org>; Sun, 11 Oct 2020 13:28:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=if/+BSOS1wmVyuomsGPC6whY39/vBqwHxq7hvAVvs40=; b=sW//BHo2gNLzZ5POP6t4mzYoQoSwl5Mmw4LK6xo2kbHYsyNFNEf8sHlW1O+/xrEdhG CBF7tU49ksYKBpdIb8T4tKL1SLLOG9q6UP6Ar2TN2zaZueFqn957q+kV2Mwfh7F7K9Ad zhrB+b3V+7Wt3TN+qbBXbMru8Ov7iX5M+j4cdy12toYfliNNq2DE4prKkjXbkcUIw1nN DYlPnmJuUYD3vqTMOVRVVvlRrHMDx2LVgqyogGc0PN17Ix9FbbaIfJqPQo2aeX9MfU0m 9L6cyfR/jwdaEpRgjm/R0YfYB6kPtXfr8pvLiGIkoDbRgRwY73sDHNh9eGavXshcPZkC L/vg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=if/+BSOS1wmVyuomsGPC6whY39/vBqwHxq7hvAVvs40=; b=neGACkm97SKUYkQjWCpMnV+SoRC2eTMCC015ieXqQbM0avlczgHOp+kUsvz8qQdFx9 mtTMoPmHv14CBzAQtqG7bAMoaEBahMM42Pnqp3bduR2ZKxBodgxMpz3md+SeHW1790CJ Bdka3Y8ZvoM1uNofB6n7FFJNsofXxQM0FIYD/BVgjvLcXRSldZ9vAPLeT77y+Wm5jmbP Bw1Qi5UUW0+7nztD0e1z0xCv7UakuXjlP5fr0SsPRinl4Hn1jkYmpDgv5YbGlprCL2k8 ImE4NlC0DiPkoxGN9zlBVdL55tk1ZALCiWKCUxB18xUhgRKOf/LN4FbfjGZIJVHAaLF5 fuug== X-Gm-Message-State: AOAM5307QT13tf+1B2fAM0aM09eYeI2lbdHqtMAmosW6+wpXIB/3m0hQ Num3woKJU2Ai9Zr59CvsCc3hz3LMcUc= X-Google-Smtp-Source: ABdhPJwdn0WvvBPyt/tpxR9iR791uPIvPMZjZgKS3q2S+xbOdZ4hXznOslaqF2hhw5oJhhof+RKqsA== X-Received: by 2002:a05:651c:1190:: with SMTP id w16mr8894324ljo.36.1602448091410; Sun, 11 Oct 2020 13:28:11 -0700 (PDT) Received: from muffinmac ([91.206.110.168]) by smtp.gmail.com with ESMTPSA id t19sm3172992ljk.67.2020.10.11.13.28.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 11 Oct 2020 13:28:10 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> <m24kn9i51g.fsf@HIDDEN> <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> <m2sgaquqg2.fsf@HIDDEN> <fbff5fc9-d8cb-bae4-05a7-be1822eccfd5@HIDDEN> Date: Sun, 11 Oct 2020 23:28:08 +0300 In-Reply-To: <fbff5fc9-d8cb-bae4-05a7-be1822eccfd5@HIDDEN> (Dmitry Gutov's message of "Thu, 8 Oct 2020 01:47:29 +0300") Message-ID: <m2sgakld7r.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: >> Can you please advice me what this change should look like? Get rid >> of calling 'vc-call'? > > Yes. How about the attached patch? Small fix: THEN and ELSE blocks of the '(if dir...' should be swapped. Does those kind of changes should be applied to any function that uses 'vc-call' and can be called on dirs? Is there any reason to use 'vc-backend' at all? 'vc-responsible-backend' will call 'vc-backend' on a file that is not a directory. >> In this case the function 'vc-version-backup-file' >> must be changed as well. > > Does it actually make sense to use it on a directory? Looks like it make sense for CVS backend. Take a look at 'vc-cvs-stay-local-p'. > Something like that. Or 'git init' inside a subdirectory. Not a > frequent occurrence, but if we start using directories and files > interchangeably in more places, we are likely to start caching other > properties on them, too. So it's better to use a different function to > detect which backend a directory belongs to. In this case `vc-call` must use that function, right? > Also, your patch makes vc-registered work on directories. How is that? 'vc-registered' is still returns nil for directories. The changes affects only the side effect of it.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 7 Oct 2020 22:47:44 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 07 18:47:44 2020 Received: from localhost ([127.0.0.1]:58298 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kQIDn-0006Wf-Vi for submit <at> debbugs.gnu.org; Wed, 07 Oct 2020 18:47:44 -0400 Received: from mail-wm1-f53.google.com ([209.85.128.53]:34713) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kQIDi-0006WO-BR for 43464 <at> debbugs.gnu.org; Wed, 07 Oct 2020 18:47:42 -0400 Received: by mail-wm1-f53.google.com with SMTP id l15so5457733wmh.1 for <43464 <at> debbugs.gnu.org>; Wed, 07 Oct 2020 15:47:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language; bh=GnhvDutm5JjDHpurP3rVNjBbUtIUp8G/8J1Z5v/jR7U=; b=LoHi/WpZHAnTscloOijuTH7LdpK9TWS/pRAWOjq598frYTpHAG8E/nAnfciNbV5e45 hSwO7kJx6AoL+/FcwJAC8s71TRnMg6VNgZVCifqfzn9woxt7qR0+3S6yxYe0m6JtOpSp GyNXsY+OJ+qv++f5P1v20TWbCdg7SZHxjBhQItzOOYh4ZAQfjWvSC/P+J2ktjDsj3ZAT TugaXS+clN3kVksp79dqGCk0Sgv9GK7gbgxodqX8DZ7f7pm7+VrZNM/76vV+O0gkV7v6 W4IaYDUUuP8Cy1xI1fNSGSNSYVkq/tS6Tbxv550O4P/RNOjjEuVoJSGb2nChL1zcGZ3r GEZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language; bh=GnhvDutm5JjDHpurP3rVNjBbUtIUp8G/8J1Z5v/jR7U=; b=lUXCujX82tJCq9EBrk54kmRIH7q7NT+SAKs9Lon7MKKS5uXEv4fg0zDXY0oKOTPWsC 0piDO2V+raxKjYCVcLFLSVUp751V6zBBC8dwZzjmn0N1u+lWxqd+Pw5KkAsqrPnwcg5c DEfs+oDrqOfyjpLqX+9dMQJ/2ZiAiYiGte2lhOKC2j+PdLhzwJY7fz1j7kkReLOIppUl XK77i37JeyFc+y5qy+b3puotTiTW6+eWtCzT9JPIkTcRmQ8M2etCDYlgxD9wNvhHHYQV WHrTOjvAWBFsJ2O+XJCleKmlqwrI3OlFIdMtItwlutapkJLNy8Mxfp5M9uFvppUPLY3A MYPg== X-Gm-Message-State: AOAM530NpmJ+rAd0qw1iSYB+vu3a8p67lK3Fg8CA9p91qFepMnhpqn7l xBQoQbUMLiCLeJc+rapiUSdXScrOkyNKJQ== X-Google-Smtp-Source: ABdhPJxPlvYAqQimrF2bp12eB834bkoKhMxunzKUZiF+L7FjqWAP9TZEKPovb7fOed+h7gycACe9lw== X-Received: by 2002:a05:600c:2902:: with SMTP id i2mr5374201wmd.31.1602110852168; Wed, 07 Oct 2020 15:47:32 -0700 (PDT) Received: from [192.168.0.4] ([66.205.71.3]) by smtp.googlemail.com with ESMTPSA id f63sm4497966wme.38.2020.10.07.15.47.30 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 07 Oct 2020 15:47:31 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> <m24kn9i51g.fsf@HIDDEN> <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> <m2sgaquqg2.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <fbff5fc9-d8cb-bae4-05a7-be1822eccfd5@HIDDEN> Date: Thu, 8 Oct 2020 01:47:29 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m2sgaquqg2.fsf@HIDDEN> Content-Type: multipart/mixed; boundary="------------79EA94F4F3860436BFC712D7" Content-Language: en-US X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) This is a multi-part message in MIME format. --------------79EA94F4F3860436BFC712D7 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 07.10.2020 16:16, Andrii Kolomoiets wrote: > Dmitry Gutov <dgutov@HIDDEN> writes: > >> On 05.10.2020 09:02, Andrii Kolomoiets wrote: >>> Dmitry Gutov <dgutov@HIDDEN> writes: >>> >>>> Where is that vc-backend called from, in our scenario? >>> It's called from 'vc-call'. The 'vc-revert-file' used it twice >>> to call the 'make-version-backups-p' and the 'revert' backend functions. >> >> Then a change in vc-revert-file could be sufficient. > > Can you please advice me what this change should look like? Get rid of > calling 'vc-call'? Yes. How about the attached patch? > In this case the function 'vc-version-backup-file' > must be changed as well. Does it actually make sense to use it on a directory? >>>> Could we make do with changing that code to use vc-responsible-backend >>>> instead of vc-backend instead? If it's not a function called >>>> frequently. >>> I went a little different way and made the 'vc-backend' return >>> correct >>> backend for directories. In case you missed it somehow here is the link >>> to the message: >>> https://lists.gnu.org/archive/html/bug-gnu-emacs/2020-09/msg02508.html >> >> Like I explained, it will create a cache entry that is never invalidated. > > In what way VC backend for directory could be changed? Like 'rm -rf .hg > && git init'? We can make the 'vc-backend' function to ignore cached > backend for directories. Though I think it's not efficient. Something like that. Or 'git init' inside a subdirectory. Not a frequent occurrence, but if we start using directories and files interchangeably in more places, we are likely to start caching other properties on them, too. So it's better to use a different function to detect which backend a directory belongs to. Also, your patch makes vc-registered work on directories. What does it mean to have a directory "registered"? It's not a well-defined notion, given that most of contemporary VC systems don't track directories, only the files inside them. --------------79EA94F4F3860436BFC712D7 Content-Type: text/x-patch; charset=UTF-8; name="vc-revert-dirs.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="vc-revert-dirs.diff" diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 3852a64550..8efd9fd560 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -2788,14 +2788,21 @@ vc-version-backup-file backup-file))))) (defun vc-revert-file (file) - "Revert FILE back to the repository working revision it was based on." + "Revert FILE back to the repository working revision it was based on. +FILE can be a plain file or a directory, and in the latter case +all files inside that directory will be reverted." (with-vc-properties (list file) - (let ((backup-file (vc-version-backup-file file))) + (let* ((dir (file-directory-p file)) + (backup-file (unless dir (vc-version-backup-file file)))) (when backup-file (copy-file backup-file file 'ok-if-already-exists) (vc-delete-automatic-version-backups file)) - (vc-call revert file backup-file)) + (vc-call-backend + (if dir + (vc-backend file) + (vc-responsible-backend file)) + 'revert file backup-file)) `((vc-state . up-to-date) (vc-checkout-time . ,(file-attribute-modification-time (file-attributes file))))) --------------79EA94F4F3860436BFC712D7--
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 7 Oct 2020 13:16:26 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 07 09:16:26 2020 Received: from localhost ([127.0.0.1]:55583 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kQ9Iw-0000de-8Z for submit <at> debbugs.gnu.org; Wed, 07 Oct 2020 09:16:26 -0400 Received: from mail-lj1-f175.google.com ([209.85.208.175]:36494) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kQ9Is-0000dN-Og for 43464 <at> debbugs.gnu.org; Wed, 07 Oct 2020 09:16:24 -0400 Received: by mail-lj1-f175.google.com with SMTP id r24so1938560ljm.3 for <43464 <at> debbugs.gnu.org>; Wed, 07 Oct 2020 06:16:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=6RRfqsbIa6PVU+u4Gqsgz20ccLTx+1rqs5I59wfEsII=; b=dwL9IeTPnNIvmf7egV9jEacJITF3j1rBf/2hHAIVP5DTtWjLj4E3VqG1qjqrrrf6Lt YQm97doO/FDaKdNhL7XQY3Wr72OvdAkdY0ej3Ej/haxYDE6G9hUhZkAsbFyVdCoVYdC/ /KqadcFmwQOd6FIQktVPM1FIu3Y0UDJiY5/bwce/4MgeVqFsEnQD9IDJbKidxuAYqEGr bsKOTfkChpj1/F7Y7CEmm9UZpU/OKsisDqI2BfjrmHE7v6yQ1CfP9lfraevGD/Iqvjjl pvrELXGAcTYVG99HBewx/jzOf6K9v33ZHKi2E7m1nu6FGxP7q9eDY0YwVKSa331uXdag zu4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=6RRfqsbIa6PVU+u4Gqsgz20ccLTx+1rqs5I59wfEsII=; b=iYAmTTyiTadQYWJPYzIqDY1xs3p0jcdtvqvwPFxJwrzmj8m/G9rDVY8WqC7QJsNA1l 33TEE8zBn0m1+ZSda4eCtlg8ZuKamF1f8nCF7DqqiNRsQehK6HPUJX5aYB6ODSLme2/n 64R2+xhmGE4BuUuWR5k3qWCHQR4VYbZanXTAwyP+1ew5jxDtkyl065cOy0j1Y+fjwc96 16Jok/x5UlS9Uk6Wc/DHyEAwTgDexAYd5qSWzdbs5so/IP5Jix1QIK6QzpEygt/iDa6q lzwdtWLLOmcV7nYz0Q0jnf3+CmLZTUKlm0euYIDiLyQFSoLZKsZ/PfVtOFIc97LkDuW+ Sxvg== X-Gm-Message-State: AOAM532HXUGf/+JmHjIJAZfPTtLubqXnANE45xU/JYguj17vj5Nyilvz KLnRkuR/gOinKJitfwsnnyLaWCvJpLA= X-Google-Smtp-Source: ABdhPJx+8H2PN9retDDWNfBb0BMEf6r/DWG0/7Y3BsKZICEZiJI4hNSFMXvcv+SfxKDDQbL/sBnJwA== X-Received: by 2002:a05:651c:327:: with SMTP id b7mr1125484ljp.140.1602076576166; Wed, 07 Oct 2020 06:16:16 -0700 (PDT) Received: from muffinmac ([91.206.110.168]) by smtp.gmail.com with ESMTPSA id q11sm331241lfc.309.2020.10.07.06.16.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Oct 2020 06:16:15 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> <m24kn9i51g.fsf@HIDDEN> <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> Date: Wed, 07 Oct 2020 16:16:13 +0300 In-Reply-To: <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> (Dmitry Gutov's message of "Mon, 5 Oct 2020 13:19:19 +0300") Message-ID: <m2sgaquqg2.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: > On 05.10.2020 09:02, Andrii Kolomoiets wrote: >> Dmitry Gutov <dgutov@HIDDEN> writes: >> >>> Where is that vc-backend called from, in our scenario? >> It's called from 'vc-call'. The 'vc-revert-file' used it twice >> to call the 'make-version-backups-p' and the 'revert' backend functions. > > Then a change in vc-revert-file could be sufficient. Can you please advice me what this change should look like? Get rid of calling 'vc-call'? In this case the function 'vc-version-backup-file' must be changed as well. >>> Could we make do with changing that code to use vc-responsible-backend >>> instead of vc-backend instead? If it's not a function called >>> frequently. >> I went a little different way and made the 'vc-backend' return >> correct >> backend for directories. In case you missed it somehow here is the link >> to the message: >> https://lists.gnu.org/archive/html/bug-gnu-emacs/2020-09/msg02508.html > > Like I explained, it will create a cache entry that is never invalidated. In what way VC backend for directory could be changed? Like 'rm -rf .hg && git init'? We can make the 'vc-backend' function to ignore cached backend for directories. Though I think it's not efficient.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 5 Oct 2020 10:19:30 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Oct 05 06:19:30 2020 Received: from localhost ([127.0.0.1]:48006 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kPNac-0003LD-8D for submit <at> debbugs.gnu.org; Mon, 05 Oct 2020 06:19:30 -0400 Received: from mail-ed1-f46.google.com ([209.85.208.46]:40814) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kPNaa-0003Kw-IG for 43464 <at> debbugs.gnu.org; Mon, 05 Oct 2020 06:19:29 -0400 Received: by mail-ed1-f46.google.com with SMTP id p13so2728869edi.7 for <43464 <at> debbugs.gnu.org>; Mon, 05 Oct 2020 03:19:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=e7c+qpxmLPGYul7LbQkPPuwJvMweWj6SPE8yFmpPXyE=; b=Nxc4RAHYZD7t3hcu/7Ycl2Nz6ZO35JeGD+pg4RwDBuRtpR6WZbqaei6vhxW0JjuN1Q Upd1CymSiIllAPsNGuLdiiYQWO38o9tCidR3YJpvtFPUwB4INLcd0zqvSdzjA951wOZO ZZFbZ+BMVQ1EU373JBU8VXXwaWi9aFzy9Tp6Dzqzo/2JQtWn7qbW4QUDWNJy8FY84YMl /qc31n4Rbaj8bG6fgPC2dQYCDt1Ovy2vrGBpZ9cMGk6t4LwRrN9sI3uf6NWjKOP34zdu bW5B407mTb58WGvgDAB4ilPUrJ/16alDSOa3X7Aj/8Zln0lrlQt0+Rb14VYP+z1IznYI 98SQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=e7c+qpxmLPGYul7LbQkPPuwJvMweWj6SPE8yFmpPXyE=; b=jxlngYEYTg0CBKYcRggOYLg5rqjuwPtARwH/DrmJ6fGGSLFSlCd/0ksrmHoltzhfIH mMfIkJNSXXKbkp8qGhDgHTlROdoPsJXm55m+oPrUasdEOHVypg1bp3YzRWVZKDeE+OgV 43ULumn8fRzDEu0cYacv6l4XUyHURJAjxaYABudstLyj1fmDHUR6TY75DWlPi0Md6DVP LJi65wAh/bt9ClZBYCviKiyezPYV+pD1tUIVwGrnwnp2hkvq8JrvRpKY0Xy4v12C0vld xnl91J+eV1qjtVOOpW2NrCIVC/MGAj1pwP9c5YZ24GNriaPL4ucQqwlJLvm4xL9KA7h2 C9rw== X-Gm-Message-State: AOAM530PbuPUe3oITChPixQMZgjOSgv6Q+DCXksw7xL4IXmoy/wGQOht n5jDrxeFlqA3hx1dpmjAX/twNOfjBY1ccA== X-Google-Smtp-Source: ABdhPJx4puq7hHv5vLtAttBlPfUbm6Si7HdW/1HOeyQ55h5HjSKKRlJVMxZirZLc6ifsUoDAzjHZvg== X-Received: by 2002:a50:ab59:: with SMTP id t25mr15679701edc.364.1601893162408; Mon, 05 Oct 2020 03:19:22 -0700 (PDT) Received: from [192.168.0.4] ([66.205.71.3]) by smtp.googlemail.com with ESMTPSA id n25sm2813277ejd.114.2020.10.05.03.19.20 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 05 Oct 2020 03:19:20 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> <m24kn9i51g.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <b62c3bbb-448b-c125-3cb3-60ba546985d8@HIDDEN> Date: Mon, 5 Oct 2020 13:19:19 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m24kn9i51g.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) On 05.10.2020 09:02, Andrii Kolomoiets wrote: > Dmitry Gutov <dgutov@HIDDEN> writes: > >> Where is that vc-backend called from, in our scenario? > > It's called from 'vc-call'. The 'vc-revert-file' used it twice > to call the 'make-version-backups-p' and the 'revert' backend functions. Then a change in vc-revert-file could be sufficient. >> Could we make do with changing that code to use vc-responsible-backend >> instead of vc-backend instead? If it's not a function called >> frequently. > > I went a little different way and made the 'vc-backend' return correct > backend for directories. In case you missed it somehow here is the link > to the message: > > https://lists.gnu.org/archive/html/bug-gnu-emacs/2020-09/msg02508.html Like I explained, it will create a cache entry that is never invalidated.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 5 Oct 2020 06:02:47 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Oct 05 02:02:47 2020 Received: from localhost ([127.0.0.1]:47514 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kPJaA-0002cp-GE for submit <at> debbugs.gnu.org; Mon, 05 Oct 2020 02:02:47 -0400 Received: from mail-lj1-f175.google.com ([209.85.208.175]:37010) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kPJa8-0002as-Iw for 43464 <at> debbugs.gnu.org; Mon, 05 Oct 2020 02:02:45 -0400 Received: by mail-lj1-f175.google.com with SMTP id n25so6278695ljj.4 for <43464 <at> debbugs.gnu.org>; Sun, 04 Oct 2020 23:02:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=kEqsNj+tXsfmk98/tgBhdN6fiY1RpGfhSHa858lYfbg=; b=jTKXCy97nMeyc082QKlgoQ9VMQFaDGocvpjD4m1eXbIcjQHbT9ZvnuUsxMEj6V+Yjg EjUte7cVLGS3RTz5WjXfBRX5sLkipQ19LqD1g98JaKNy/1RWYrrZMfnVdRWcWM1BuCkk KdcXMuYWEw/0Q/sk6RjQzslT/IHpsCln1d2AoxBL1ud62AwHbcPACAsldKgUzCpuPfBh n8xqq0y0nCSozO3RA2qWO9fN24xmoTb+MNwVsmQj8CbFtT9dFUDnnjcYeSNVE7eB/jUu 586D9hBR8OHelinmNeswIY6WQeO4B2r30jXbO4+FHvTn5BdSySCX1sMvvTXdA2buARYe 4ABg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=kEqsNj+tXsfmk98/tgBhdN6fiY1RpGfhSHa858lYfbg=; b=eH1bFu1wZJ4te24MlYup+RA5dh6ieFp5KOzA49vKL65tlf+diDMQ3IaZVVXuIzNDUn cMQYTmWlhMaLD7wrvnin213zCIZodjynbDsfvWN9A8AGzybRpLw1C5UoqovWPnAZzvTI umrfsPoUCz8Km1eTCTkKx+xHUNwJifsXoS0cNEC/R3OEWTYrlbcDS9JzhSyXex38Cd8l /JNnjMB9vlinloFapPyhAlW6eDSDSAKvRqtjg3OPrwQBW7U5bHzF7NjX18ligNEQSCAB WoPuYV6Qb47wsiaqtXcIFhCi/MQ7NI9okxZfCgCJD/61MUIpouKA/KjJNXmJB1kdT9J/ uAMQ== X-Gm-Message-State: AOAM531EKHpZ4KayM3zEq3kH2qM5ox90lAD+12+6MXwaX7K6SqAG/WXL Qj5Vhvpyy1KKo2l7emPDqK/LQUmQ5aE= X-Google-Smtp-Source: ABdhPJxXfMkCzWgxKDoLdOH8xoF8xFMOYKp79oDIpDiNODfEM1Bm9PyqUxsfOAukgB0FOr1Gneqfeg== X-Received: by 2002:a2e:9bc5:: with SMTP id w5mr3607769ljj.454.1601877758080; Sun, 04 Oct 2020 23:02:38 -0700 (PDT) Received: from muffinmac ([91.206.110.145]) by smtp.gmail.com with ESMTPSA id z141sm2675806lfc.171.2020.10.04.23.02.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Oct 2020 23:02:37 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> Date: Mon, 05 Oct 2020 09:02:35 +0300 In-Reply-To: <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> (Dmitry Gutov's message of "Mon, 5 Oct 2020 01:32:10 +0300") Message-ID: <m24kn9i51g.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: > Where is that vc-backend called from, in our scenario? It's called from 'vc-call'. The 'vc-revert-file' used it twice to call the 'make-version-backups-p' and the 'revert' backend functions. > Could we make do with changing that code to use vc-responsible-backend > instead of vc-backend instead? If it's not a function called > frequently. I went a little different way and made the 'vc-backend' return correct backend for directories. In case you missed it somehow here is the link to the message: https://lists.gnu.org/archive/html/bug-gnu-emacs/2020-09/msg02508.html
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 4 Oct 2020 22:32:21 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Oct 04 18:32:21 2020 Received: from localhost ([127.0.0.1]:46927 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kPCYH-0008Iq-6u for submit <at> debbugs.gnu.org; Sun, 04 Oct 2020 18:32:21 -0400 Received: from mail-ej1-f41.google.com ([209.85.218.41]:45376) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kPCYF-0008Ic-84 for 43464 <at> debbugs.gnu.org; Sun, 04 Oct 2020 18:32:20 -0400 Received: by mail-ej1-f41.google.com with SMTP id i26so9193242ejb.12 for <43464 <at> debbugs.gnu.org>; Sun, 04 Oct 2020 15:32:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=qeA82m5Gb++RIR+oXtmSNu/PJeKSWBs+x9b6atz1ty0=; b=PPqfFUBqB6bNJdIYoLs9BKu7BtmNeKDIbZeclSHKT0HkpDHf318F1RQxW0lTo0DPZH XdRq/mKmN/27M0LkG4mgPzsEs+IQEo91uKcv2mwwNUg9i99mGFemLDp+Wqr5yS5f+h2Q kN99qZQ225hOn4/tk2ckd/Nl0Cy0gC0MXYsetzeKm3h9dNcuhONJEqoRu/OLDZEbvrWL 1RXkTDr2yLgFtp7OL5LTg+XHgjZ6qV0EfSX1Mjtv8Yt+Eed04+WRCgPQtvkeJi3dJKm4 BIFesWuAuorib+arvAQPmntvE6fI0/3rLAarjSjHy4Hbabq1hsKaBJcViqNlnqDwhcJS ahww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=qeA82m5Gb++RIR+oXtmSNu/PJeKSWBs+x9b6atz1ty0=; b=FJN4PT5HRr7PTP6Ill2h7mGIxC3WBSzAHGOx4Scg1i57uRRnxucYg0pRe5wkurmr/7 iJz8Ahw/hPS9QTpcGBWhw4VoDth0QjEqP87wQLK0YD+e0gfwEYPrUieGPe3afT7oAmt2 GMcvNmtgfs7O5LZNwWQj9TRWoAw66VYsd2xll7A8HAmS3fl8P52OpJ6wBPz9TkFZZxLJ IoRSh5KCH7/0ruvEHl+iy1W3DDjrn2DG+uXoe1Z3S/C3CbHE+QHSOtpPvqGw1xT4Gm1k uakA/gIb5tOvwT3Ka2zuU3ptIOsyO0zSUoVfcVTp/EKFVbxnnqPhxIYxA/gdyDbF54U1 7wLw== X-Gm-Message-State: AOAM533bTLgjzg3Wnt0009Nv5vDlN1YU644SBsRv/ZkihpGxB9Hw+C5w yvxuO0tVOIkDmkhDsKRB47oH2ZUYgusRvw== X-Google-Smtp-Source: ABdhPJyvN1Qtfa3wa3HVWUa4KIK6HCTh/XSdAvBpi8/v/yBNM7ypHQtOu82aCIVspCc2TFlIbajnXA== X-Received: by 2002:a17:907:9ef:: with SMTP id ce15mr8405870ejc.430.1601850732673; Sun, 04 Oct 2020 15:32:12 -0700 (PDT) Received: from [192.168.0.4] ([66.205.71.3]) by smtp.googlemail.com with ESMTPSA id dt8sm6275065ejc.113.2020.10.04.15.32.10 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 04 Oct 2020 15:32:11 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <7b4d0bcf-c622-b2db-34d6-e587fe516f8d@HIDDEN> Date: Mon, 5 Oct 2020 01:32:10 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m28sczwsqe.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) On 24.09.2020 10:15, Andrii Kolomoiets wrote: >> On 18.09.2020 18:45, Andrii Kolomoiets wrote: >>> BTW vc-revert is also works fine in Git repo when point is on >>> subdirectory. So for the vc-git only reverting repo root is not >>> working. >> >> That's an interesting observation. > > And the most interest part of that observation is that I can't reproduce > it :) Oh well. :-) >>> Please see attached patch which make it possible for vc-hg to revert >>> directory. >> >> Could you explain both changes in that patch? > > The idea is to make the 'vc-backend' function to return backend for > directory. 'vc-backend' function uses the 'vc-registered' function. > The change for vc-hg.el makes 'vc-hg-registered' return t for directory. > The change to vc.el makes the 'vc-register' function called on directory > to not error with "already registered" message. Thanks. Where is that vc-backend called from, in our scenario? Could we make do with changing that code to use vc-responsible-backend instead of vc-backend instead? If it's not a function called frequently. I'm not 100% sure about the original design, but vc-responsible-backend *does* work on directories. Its downside is it doesn't cache the result to VC properties (hence it would be unwise to use it everywhere). But it's also an upside, because said properties are invalidated in a few strategic places like find-file-hook, and that never happens for directories (hence that cache will tend to get out of date, sooner or later). >> And also: how does it change, or not change, the behavior of vc-revert >> in backends that are not Git or Hg? > > Looks like everybody is ready for reverting dirs. > > bzr, mtn, svn - Should be fine reverting directory > dav - do nothing on vc-revert > rcs - reverting directory is added in c22b0a7da32360e34f6f0ff86a886c9028b3d863 > sccs - reverting directory is added in e7290559824406d111d306069b36dde8ced847f9 > src - reverting directory is supported initially 1e81f6769013e1a0df9e10d7c5d0a3e3ca131143 > cvs - passing directory to 'unedit' command should be fine Very good.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 30 Sep 2020 09:13:54 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 30 05:13:54 2020 Received: from localhost ([127.0.0.1]:58172 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kNYBO-0005wv-94 for submit <at> debbugs.gnu.org; Wed, 30 Sep 2020 05:13:54 -0400 Received: from mail-wm1-f43.google.com ([209.85.128.43]:34947) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kNYBK-0005wf-6a for 43464 <at> debbugs.gnu.org; Wed, 30 Sep 2020 05:13:52 -0400 Received: by mail-wm1-f43.google.com with SMTP id y15so905061wmi.0 for <43464 <at> debbugs.gnu.org>; Wed, 30 Sep 2020 02:13:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=jG9rWu6E9BNwVHrX85h+8Hv7ZQsEBrNzDxHxCVl3fow=; b=App2NZ6Crw7ZpmYLjYFv2zIUL7oL1KliHTE4ju9tAHncHKYt6tY0c23JllsvGmCYto oz2Lzga0AQwMesm/lMTH7FgPE5yzvpz700Z9v2ZVmjfjOIEkl2zHj3krov+8kCf5Ldc+ +Jv2DlPvy6t9eSLQ6mboNTh2T0jTfBI56Kg71iq2k+jK7fyEVuL6rbxBAAcAkAJv5HFZ +ZZUSD2j7aRxOMc4OP3lda4j1Ai8XCjTRdR+qyWcYYbIZYJ82iOG6P4Hif4tDd917Om8 swUB7h3CYBD8U1nP8mrQg52+6ZcjCrz8q08ajHLvW94J1PXdP0mKfg8aMpu3qCyhsWAa LUjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=jG9rWu6E9BNwVHrX85h+8Hv7ZQsEBrNzDxHxCVl3fow=; b=nf2OnjNg2KPrpSUL4YzZPGZoplsueJ3zQDOtGKetf2YTL8+rcRX1mulKUeuqb3eBxo cIb4lkhLvqL7gnTlRb62t44eandUAXuZEwuUkgfm+eCTTGgPHIUnvla0wQ4tKWvdTPey YhDwxa9U6oxOIdMurMGrzgN9mCgLELQJkuyZotwF6d13IqbgVdXjHaoq9MKlrypu5yZ5 vhaic58jZzW7MTNPDf8c5WMAKfKhhEh5gkgydsZBMf0/ex7IG1xg2w1GaNZOpkJxn8x5 ZYdYkOSxTwg3r28GYvk1qM4OoHGJryne6Wbb+k+d95IZHM3HjlLfSzM6dB9MDGQabsEm ehuQ== X-Gm-Message-State: AOAM532ULGRlh7ORGuK/N+f0HpW7kd+O1aDb9H/Q4E3jofj3YDy6sv3j F9ovpeyRHOHExuVZmptlEGvFG+tK05Q= X-Google-Smtp-Source: ABdhPJz3uAUXs5U9lCKGq57nxxF0l64O+V5GN4VxJLxxFwaL2nBrNcEHoYCwNhVQUWjZmY4F7N3Omg== X-Received: by 2002:a7b:c103:: with SMTP id w3mr1870289wmi.24.1601457223895; Wed, 30 Sep 2020 02:13:43 -0700 (PDT) Received: from muffinmac ([91.206.110.145]) by smtp.gmail.com with ESMTPSA id u66sm1600612wme.12.2020.09.30.02.13.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Sep 2020 02:13:42 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> <m28sczwsqe.fsf@HIDDEN> Date: Wed, 30 Sep 2020 12:13:41 +0300 In-Reply-To: <m28sczwsqe.fsf@HIDDEN> (Andrii Kolomoiets's message of "Thu, 24 Sep 2020 10:15:21 +0300") Message-ID: <m2y2krd3ui.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.6 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.6 (-) --=-=-= Content-Type: text/plain Andrii Kolomoiets <andreyk.mad@HIDDEN> writes: > Dmitry Gutov <dgutov@HIDDEN> writes: >> Could you explain both changes in that patch? > > The idea is to make the 'vc-backend' function to return backend for > directory. > > `vc-backend` should return correct backend for directory and the > behavior of `vc-registered` must be kept unchanged. Please see attached patch. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-vc-backend-for-directory.patch From 8b097942a3fbaf5b6d27fa61b2d3e5357d79beb8 Mon Sep 17 00:00:00 2001 From: Andrii Kolomoiets <andreyk.mad@HIDDEN> Date: Wed, 30 Sep 2020 12:02:21 +0300 Subject: [PATCH] vc-backend for directory * lisp/vc/vc-hooks.el (vc-registered): Use 'responsible-p' vc backend function to find backend for directories. (vc-backend): Don't depend on 'vc-registered' result because it nil for directories; always read 'vc-backend' property. --- lisp/vc/vc-hooks.el | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/lisp/vc/vc-hooks.el b/lisp/vc/vc-hooks.el index f09ceddcb3..b20e2e0b00 100644 --- a/lisp/vc/vc-hooks.el +++ b/lisp/vc/vc-hooks.el @@ -336,12 +336,15 @@ vc-registered ;; There is no file name handler. ;; Try vc-BACKEND-registered for each handled BACKEND. (catch 'found - (let ((backend (vc-file-getprop file 'vc-backend))) + (let ((backend (vc-file-getprop file 'vc-backend)) + (fn-result (if (file-directory-p file) + '(responsible-p) + '(registered . t)))) (mapc (lambda (b) - (and (vc-call-backend b 'registered file) + (and (vc-call-backend b (car fn-result) file) (vc-file-setprop file 'vc-backend b) - (throw 'found t))) + (throw 'found (cdr fn-result)))) (if (or (not backend) (eq backend 'none)) vc-handled-backends (cons backend vc-handled-backends)))) @@ -361,9 +364,8 @@ vc-backend (cond ((eq property 'none) nil) (property) ;; vc-registered sets the vc-backend property - (t (if (vc-registered file-or-list) - (vc-file-getprop file-or-list 'vc-backend) - nil))))) + (t (vc-registered file-or-list) + (vc-file-getprop file-or-list 'vc-backend))))) ((and file-or-list (listp file-or-list)) (vc-backend (car file-or-list))) (t -- 2.15.1 --=-=-=--
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 24 Sep 2020 07:15:33 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Sep 24 03:15:33 2020 Received: from localhost ([127.0.0.1]:38511 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kLLTY-0005bU-Qy for submit <at> debbugs.gnu.org; Thu, 24 Sep 2020 03:15:33 -0400 Received: from mail-lf1-f45.google.com ([209.85.167.45]:41945) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kLLTV-0005bC-QX for 43464 <at> debbugs.gnu.org; Thu, 24 Sep 2020 03:15:31 -0400 Received: by mail-lf1-f45.google.com with SMTP id y17so2703206lfa.8 for <43464 <at> debbugs.gnu.org>; Thu, 24 Sep 2020 00:15:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=rOi2ZzvehkYUxKcd1z9+OxUJP6pMj6G9VNfGODpNF+s=; b=BzJ7xmRw1sokWT5kefPa9TztNUcLHHtkz5QJxjIGWBJvQP61iK7aCDLa4MLbNmsnbc HEbKVwu0yBiRFseotuaEz25Y7UpaD/f38CbycneTP25Clr3cLotrSgsbEWALLNS5yoIV /5+sFHafdsEQZzLTZiUlzJ9e4qOV5aIWwQEr2xU3Hh23bVpe3gDNbwhotF1Mu8XrFUmM v2LJMF4MlDWo8B0O0M4Ykx8LQQ6FxO9S125hAC+tnU09T7XIbgXZfAQCf9wb1OTaRbMW 4kJFpPFxG6DMaXmpqaLx4nwZRYHp9uiiYZAtst+r/2WDGNxZFfuXV5/7Zcr616Ng88k5 gq4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=rOi2ZzvehkYUxKcd1z9+OxUJP6pMj6G9VNfGODpNF+s=; b=Kl6JbAzo0FnG/1INdBBi/7Wqh+keWWnFPpoOqJOGHhitNLq5CFWUFTB8nnreL8AzRo bgJoFQA2imCiZVwzxMF8bCGYCy8N+b7hh12BH+S5Wxq4ROKQM+uKs3MvtTv7h9UVZQD3 u6vrF65bs1XyZymI+ZBJVQ4vs2N+W7qeS1FwDJkXPNM2DFTNa0b/huqXXH0myMu9Aosb wNDZ9oJC/JFAl1V7la5IcOMp92MMLxNaftizsBUWsc/C44OP5PecLHzItlossVIuiYlc X0jX7wC90+9UOF6eQuNZk/wmuqxj3iG1Nor1cZkj82yFsl/y+VjHw2+Qtt/5QK7VtiHg Gx7A== X-Gm-Message-State: AOAM531QNoOz6ld2HgZTR2kvGUKjojiYkycNYrNxtmuBDMv1DezDDQhy hqnLBUAIc1GeoVsi3wnOM17gdc5YF6Y= X-Google-Smtp-Source: ABdhPJzj/NnCzdUuEanu13qUWFuiiniaoDhE1NbZNqAZD0Hoh91VFTqEReztlDWMdeCtubIkldN43A== X-Received: by 2002:ac2:5333:: with SMTP id f19mr1283199lfh.339.1600931723313; Thu, 24 Sep 2020 00:15:23 -0700 (PDT) Received: from muffinmac ([91.206.110.141]) by smtp.gmail.com with ESMTPSA id n2sm835429lji.97.2020.09.24.00.15.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Sep 2020 00:15:22 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> Date: Thu, 24 Sep 2020 10:15:21 +0300 In-Reply-To: <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> (Dmitry Gutov's message of "Tue, 22 Sep 2020 22:48:32 +0300") Message-ID: <m28sczwsqe.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: > On 18.09.2020 18:45, Andrii Kolomoiets wrote: >> BTW vc-revert is also works fine in Git repo when point is on >> subdirectory. So for the vc-git only reverting repo root is not >> working. > > That's an interesting observation. And the most interest part of that observation is that I can't reproduce it :) >> Please see attached patch which make it possible for vc-hg to revert >> directory. > > Could you explain both changes in that patch? The idea is to make the 'vc-backend' function to return backend for directory. 'vc-backend' function uses the 'vc-registered' function. The change for vc-hg.el makes 'vc-hg-registered' return t for directory. The change to vc.el makes the 'vc-register' function called on directory to not error with "already registered" message. Chances that the patch is completely wrong. Perhaps `vc-backend` should return correct backend for directory and the behavior of `vc-registered` must be kept unchanged. > And also: how does it change, or not change, the behavior of vc-revert > in backends that are not Git or Hg? Looks like everybody is ready for reverting dirs. bzr, mtn, svn - Should be fine reverting directory dav - do nothing on vc-revert rcs - reverting directory is added in c22b0a7da32360e34f6f0ff86a886c9028b3d863 sccs - reverting directory is added in e7290559824406d111d306069b36dde8ced847f9 src - reverting directory is supported initially 1e81f6769013e1a0df9e10d7c5d0a3e3ca131143 cvs - passing directory to 'unedit' command should be fine
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 22 Sep 2020 19:48:44 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Sep 22 15:48:44 2020 Received: from localhost ([127.0.0.1]:33468 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kKoHM-0008Mq-Gn for submit <at> debbugs.gnu.org; Tue, 22 Sep 2020 15:48:44 -0400 Received: from mail-lf1-f42.google.com ([209.85.167.42]:39853) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kKoHI-0008Ma-Oj for 43464 <at> debbugs.gnu.org; Tue, 22 Sep 2020 15:48:42 -0400 Received: by mail-lf1-f42.google.com with SMTP id q8so19367015lfb.6 for <43464 <at> debbugs.gnu.org>; Tue, 22 Sep 2020 12:48:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=2g3ItPsXoY+o+rQDDU92YjwCyDOPP90a40uS/+yj/x4=; b=mBZAQ8TTEBD+KOV2dx7YQG4+O1MhB41uKge91gFVth1NufnkhSP3iiCZr3lPz4Juw4 0Ez7TX2hbVvhWjyWQ4zN6OlRLT5XjLsrHLDKR/hqPHemdBWGyuNFrpU7ttZLfKVURrwP OqUI2q7/f36V34QldPONx7ENfehhBt9ah8CyCpMdqkIFnP+1IHIdoD4AnpBPWq7izasx e2tOGdNWx0KIQ57fvj8FnTiaaMGodBdxtT5FN+GqDhFDlj+RnUzZUAk21o6NYY02VfRY g37eBnxgC773IvGk5RuBFcz9pf9WM0fkGoyr46tw8MRcSVIG9EqQ+VRh5BZRXHZ6/s3q R20A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=2g3ItPsXoY+o+rQDDU92YjwCyDOPP90a40uS/+yj/x4=; b=m241aA+A7ZuwTcOt2qZ1UBKJM01hNB1PhxS/zXq9ENXp0ITeK6BLQSJLNxn/LUa/0q EV0rDFSWvMwwHPHih/HlVeTZ4ojmI9IK2GiQinenUccFQGvBNu3aNtYtNMaSHD/YrgSa EH9QXzPDEQBIdHqjztz7Z+Uf72Nj+WkURtDxF9L2f9SSb97Ff2kBKVyqqtJlZStuz7HX kxEEI+qZpvvJMZlg8xkoPRSwmSm51Jb/NT/NQs451ISS4tPGmybENIYDaffqohDzb7QW bj1Mjt3xw6/LQzFQeEsjin771Wd/0S6Qal6JOu7zphcrC9L7hL89c1+not7S3tDtWEC+ WOvg== X-Gm-Message-State: AOAM532SEcNtiA2MBxew0+FhzC9xl3Y8npZ1ObLi6CeOuDwRL0z3fAf2 DY/1XlpbKY1IDMTIkE/cf8bhOBXPfL+JCg== X-Google-Smtp-Source: ABdhPJyyEC9rR1cKUUg27kEIFD0NzuIHug3GuEN6PtNoCtkh81hmjFm53M1iRfA53JY0en9SAwWTXQ== X-Received: by 2002:a19:7b16:: with SMTP id w22mr2082620lfc.418.1600804114218; Tue, 22 Sep 2020 12:48:34 -0700 (PDT) Received: from [192.168.0.104] ([94.229.108.16]) by smtp.googlemail.com with ESMTPSA id q7sm3815687lfr.16.2020.09.22.12.48.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 22 Sep 2020 12:48:33 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> <m2r1qzqebf.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <11761d79-1893-fdf3-843d-bea4a026fc7f@HIDDEN> Date: Tue, 22 Sep 2020 22:48:32 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m2r1qzqebf.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) On 18.09.2020 18:45, Andrii Kolomoiets wrote: > Dmitry Gutov <dgutov@HIDDEN> writes: > >> On 18.09.2020 12:30, Andrii Kolomoiets wrote: >>> Calling `vc-git-revert` or `vc-hg-revert` directly with repo root or any >>> directory within repo works fine. >> >> True. That's how Git and Hg work anyway. >> >> I'm not saying the current situation is ideal, but we'd either have to >> give up any attempt to revert a directory (with a more appropriate >> message), or somehow differentiate between different backends where it >> would or wouldn't work. > > BTW vc-revert is also works fine in Git repo when point is on > subdirectory. So for the vc-git only reverting repo root is not > working. That's an interesting observation. > Please see attached patch which make it possible for vc-hg to revert > directory. Could you explain both changes in that patch? And also: how does it change, or not change, the behavior of vc-revert in backends that are not Git or Hg?
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 18 Sep 2020 15:45:20 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 18 11:45:19 2020 Received: from localhost ([127.0.0.1]:44215 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kJIZb-0003au-EW for submit <at> debbugs.gnu.org; Fri, 18 Sep 2020 11:45:19 -0400 Received: from mail-lf1-f50.google.com ([209.85.167.50]:36469) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kJIZZ-0003TY-Ls for 43464 <at> debbugs.gnu.org; Fri, 18 Sep 2020 11:45:18 -0400 Received: by mail-lf1-f50.google.com with SMTP id x69so6626571lff.3 for <43464 <at> debbugs.gnu.org>; Fri, 18 Sep 2020 08:45:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=6Eq9F2Q7qLsN/LCTkDwDsBzu0AU0WYvkdhVJcy0mr3E=; b=RtF7fuObJ9sGArlt/gwYk1jvmPtAuzRB1RAXeNwkwGIYfbHGFDotRe9oeKBjrqDm0D vPw/ZvQtDR+45cl8s+3TjvSqYPux/uPmGdS935kdy/uRTEqszYrl+Q/XcUnAK0YgsYGD gzEc3K8f4Z0iiH+8oh++W9quJIS/53Dr74+Xze8CglRVkSOs0AnxEyn3zD18VdWE68/G kjH9uBZhOowwAip6JANKRnI2AV7E1qhUhrVbuShcmvU62L/R51p5KWbgq0gMqwFCPlJH 0CFjKgc2Uenbd5Eekr8676urfgB15Lwj1c+t0SX3f17f0aiTT+y02Pw2YADU2/dt+xZB 9wOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=6Eq9F2Q7qLsN/LCTkDwDsBzu0AU0WYvkdhVJcy0mr3E=; b=dPezF06AtuVCdrNS5DYuqTpEYksLM32IFZwL/nQNTb6OYbYgULkn1Qft07C9HvnBrR oRuhqJYBqnv2OGD4Q7LMo1xGkI7sn7WwyEL41bRTQ648jJ1yJopsDtgw/YT9nM2/Lvfq QV1CzAHQzhK8v8/G4w1EaAnDsnEMkG7ct40f480ncBwzRBj9tudBaaDOWioV4hbU74kb dA1qvFIEiGtp3ERNoFYImM9O6BQB2ZDBNs/9LZBpPhLKkf66oQp6h9jUPCzNSSqkMEOw 4pNfau5viHA1RcqBbWjPw/PJ+KDzIkxKNEZistYngjfVME6GNctionUfRSQKCMZ9vU8r fPrw== X-Gm-Message-State: AOAM5303IopKl6e7GubGJ0JzXMtAVWX9jXGHImJNYS6rNYVi3akVEbs+ AFORdWaKRvuR3c9hNjylOhl+fM+HS4o= X-Google-Smtp-Source: ABdhPJxWMfQIMwW4LxQ7SFsKYMo2HGITY4uehI5MvkIUsW9nFOAmrzwncLqpitsEw5cxed3QluiMCg== X-Received: by 2002:ac2:529c:: with SMTP id q28mr9718222lfm.104.1600443911280; Fri, 18 Sep 2020 08:45:11 -0700 (PDT) Received: from muffinmac ([91.206.110.141]) by smtp.gmail.com with ESMTPSA id 16sm680371ljr.3.2020.09.18.08.45.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Sep 2020 08:45:10 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> Date: Fri, 18 Sep 2020 18:45:08 +0300 In-Reply-To: <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> (Dmitry Gutov's message of "Fri, 18 Sep 2020 16:30:05 +0300") Message-ID: <m2r1qzqebf.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Dmitry Gutov <dgutov@HIDDEN> writes: > On 18.09.2020 12:30, Andrii Kolomoiets wrote: >> Calling `vc-git-revert` or `vc-hg-revert` directly with repo root or any >> directory within repo works fine. > > True. That's how Git and Hg work anyway. > > I'm not saying the current situation is ideal, but we'd either have to > give up any attempt to revert a directory (with a more appropriate > message), or somehow differentiate between different backends where it > would or wouldn't work. BTW vc-revert is also works fine in Git repo when point is on subdirectory. So for the vc-git only reverting repo root is not working. Please see attached patch which make it possible for vc-hg to revert directory. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-vc-Treat-directory-as-registered.patch From 47adbf50d6d3719a9fe9e350897b30917bc1220d Mon Sep 17 00:00:00 2001 From: Andrii Kolomoiets <andreyk.mad@HIDDEN> Date: Fri, 18 Sep 2020 18:38:19 +0300 Subject: [PATCH] vc: Treat directory as registered * lisp/vc/vc-hg.el (vc-hg-registered): Treat directory as registered * lisp/vc/vc.el (vc-register): Treat directory as unregistered --- lisp/vc/vc-hg.el | 5 +++-- lisp/vc/vc.el | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lisp/vc/vc-hg.el b/lisp/vc/vc-hg.el index cb0657e70a..fec2235446 100644 --- a/lisp/vc/vc-hg.el +++ b/lisp/vc/vc-hg.el @@ -222,8 +222,9 @@ vc-hg-update-on-retrieve-tag (defun vc-hg-registered (file) "Return non-nil if FILE is registered with hg." (when (vc-hg-root file) ; short cut - (let ((state (vc-hg-state file))) ; expensive - (and state (not (memq state '(ignored unregistered))))))) + (or (file-directory-p file) + (let ((state (vc-hg-state file))) ; expensive + (and state (not (memq state '(ignored unregistered)))))))) (defun vc-hg-state (file) "Hg-specific version of `vc-state'." diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 3852a64550..77ba97fb73 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -1370,7 +1370,8 @@ vc-register (let ((bname (get-file-buffer fname))) (unless fname (setq fname buffer-file-name)) - (when (vc-call-backend backend 'registered fname) + (when (and (not (file-directory-p fname)) + (vc-call-backend backend 'registered fname)) (error "This file is already registered")) ;; Watch out for new buffers of size 0: the corresponding file ;; does not exist yet, even though buffer-modified-p is nil. -- 2.15.1 --=-=-=--
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 18 Sep 2020 13:30:15 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 18 09:30:15 2020 Received: from localhost ([127.0.0.1]:41314 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kJGSt-000124-2W for submit <at> debbugs.gnu.org; Fri, 18 Sep 2020 09:30:15 -0400 Received: from mail-lf1-f50.google.com ([209.85.167.50]:44811) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kJGSr-0000u5-7Z for 43464 <at> debbugs.gnu.org; Fri, 18 Sep 2020 09:30:13 -0400 Received: by mail-lf1-f50.google.com with SMTP id d15so6109111lfq.11 for <43464 <at> debbugs.gnu.org>; Fri, 18 Sep 2020 06:30:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=orNRfqoHpH3GEu/cH19eTVN/g8x/RwB8eeRPR8SAUG0=; b=ZC87iR4uK9sifANB9ChxnBrblmo0Dn0lzB873VciJSF7iz94PUp2AZB6G4HDybOtnB ftl7tyNLNnYSfxnBrtWuBKNPwAR6eTbDNX9nDQ+xBJPBm7VU/H/vcoZg/h/+YWzQ7Kis hTfMsUQCVJGM7CODjJoI3kd3BQo5/eVwmwk5utP/6QgTQsbT5DfCr0W35haScYWZNdDe TEe00yQiLv56pngok5bbiat0m06rQMfu6uNqF/n/dfwXaHZuiGzHhutlLdLslax60fjh vZerwRtImwQHb+ChAPnV7BWVisFK5kH03l7gcZEdTVS8Wz6x3z2KBiuV79uuKz9XQJ85 9POA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=orNRfqoHpH3GEu/cH19eTVN/g8x/RwB8eeRPR8SAUG0=; b=umUdySXmM9A3toB6FF3vcPrqgwBMd/LzeI7q7ADvUSIJeCG4NdzzghCl15Tz+23qZt DI6dvc22NsRJ3SKEbCXxXwHuz3BPwVe23zN343APwYL3Ussnp5/LW9Gds6tkW4QB8L+C kkIDwRmCcy5/uL7dcFu7HGAGI9mWl/0XdckkxWc+dEFknGhDyvxeCEKerwShe7f/NiJA VLPJtuAyv4VAweJtNaPsmxgU2Z4yaWE0DtYQXgp2VtyqWI0WVe+T3Gyb7yt0uf1RXzIz N9JD1cMhFkl3JEbjRP1nDIpW++POEhC5xAlFsHgXxmLz1aImsjyadlsfCBFe8xjQxDYe uu9w== X-Gm-Message-State: AOAM5319PIKYtNp2bpilJlmuZc1/j10nMd5oTA41nvRwdtro64YLPml5 HhZGhWl/01SHTbr2lYv1HVZE3K9aXPvBuw== X-Google-Smtp-Source: ABdhPJyD88sH+dNUXMN0IZEpcs9I/mUlIwj4+SdosX/C+BBE2AnTtI0pDr/7b/rbTIgQdgQAnBqBJA== X-Received: by 2002:a05:6512:3131:: with SMTP id p17mr9699581lfd.225.1600435806747; Fri, 18 Sep 2020 06:30:06 -0700 (PDT) Received: from [192.168.0.104] ([94.229.108.16]) by smtp.googlemail.com with ESMTPSA id g15sm612761ljj.39.2020.09.18.06.30.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 18 Sep 2020 06:30:06 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN> References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> <m2zh5nqvnh.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <0b1c72d0-f8fb-a256-1563-1c43296c8edb@HIDDEN> Date: Fri, 18 Sep 2020 16:30:05 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m2zh5nqvnh.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.4 (--) On 18.09.2020 12:30, Andrii Kolomoiets wrote: > Calling `vc-git-revert` or `vc-hg-revert` directly with repo root or any > directory within repo works fine. True. That's how Git and Hg work anyway. I'm not saying the current situation is ideal, but we'd either have to give up any attempt to revert a directory (with a more appropriate message), or somehow differentiate between different backends where it would or wouldn't work.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 18 Sep 2020 13:18:19 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 18 09:18:19 2020 Received: from localhost ([127.0.0.1]:41273 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kJGHL-0000W8-7L for submit <at> debbugs.gnu.org; Fri, 18 Sep 2020 09:18:19 -0400 Received: from quimby.gnus.org ([95.216.78.240]:53900) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <larsi@HIDDEN>) id 1kJGHJ-0000Vm-C6 for 43464 <at> debbugs.gnu.org; Fri, 18 Sep 2020 09:18:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=DU2ut7JUq53o/W//Kx3fGxhaK2dI2lll8DqQBiJMLl8=; b=XhJJAljyRCxEZcR89dmA08RXVZ 7UnMpjUW8ALGXbjpCSJ4UPTp0F91HsV6+ulyi0bZUv5gnWDdVil4pNcSTPyutUDRkgFFs/FLRU5IL c70u8IaSxHBlxm1SDrGnqIEDPhdT9NGtPbiudwdO3Pua4Y2MrWMmIexpVdATzIx1oVv0=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <larsi@HIDDEN>) id 1kJGHA-0006B4-Qx; Fri, 18 Sep 2020 15:18:11 +0200 From: Lars Ingebrigtsen <larsi@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> X-Now-Playing: Stina Nordenstam's _This Is Stina Nordenstam_: "Welcome To Happiness" Date: Fri, 18 Sep 2020 15:18:07 +0200 In-Reply-To: <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> (Dmitry Gutov's message of "Fri, 18 Sep 2020 12:00:12 +0300") Message-ID: <874knvi5ps.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Dmitry Gutov <dgutov@HIDDEN> writes: > On 17.09.2020 10:29, Andrii Kolomoiets wrote: >> Debugger entered--Lisp error: (file-missing "Cannot open load file" >> "No such file or directory" "vc-nil") >> require(vc-nil) >> vc-find-backend-fu [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org, Andrii Kolomoiets <andreyk.mad@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: > On 17.09.2020 10:29, Andrii Kolomoiets wrote: >> Debugger entered--Lisp error: (file-missing "Cannot open load file" >> "No such file or directory" "vc-nil") >> require(vc-nil) >> vc-find-backend-function(nil make-version-backups-p) >> vc-call-backend(nil make-version-backups-p "/private/tmp/gittest/") >> vc-version-backup-file("/private/tmp/gittest/") >> vc-revert-file("/private/tmp/gittest/") >> vc-revert() >> funcall-interactively(vc-revert) >> call-interactively(vc-revert nil nil) >> command-execute(vc-revert) >> At least for `hg` and `git` backends. Maybe because `vc-registered` >> for >> repo root is nil. > > I don't think we support vc-revrt on directories, repo root or not. Ah, we basically get this error message whenever we type `C-x v u' in a vc-dir buffer when not on a file (or there are no marked files)? That seems like a suboptimal error message in this case, though. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 18 Sep 2020 09:30:53 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 18 05:30:53 2020 Received: from localhost ([127.0.0.1]:40879 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kJCjF-0002rp-0c for submit <at> debbugs.gnu.org; Fri, 18 Sep 2020 05:30:53 -0400 Received: from mail-lf1-f43.google.com ([209.85.167.43]:43889) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kJCjD-0002rY-2q for 43464 <at> debbugs.gnu.org; Fri, 18 Sep 2020 05:30:51 -0400 Received: by mail-lf1-f43.google.com with SMTP id y2so5371549lfy.10 for <43464 <at> debbugs.gnu.org>; Fri, 18 Sep 2020 02:30:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=5kOYueUK0kPfwRXMnuMB7CxzXwrggDpW7Nff97eecNw=; b=jdNL8N/QnV6c2fvD5jMMlgC1WRTjNtqfpxxSgNVE1NSn5ldZb+qZqf5JD4CIUZmpSx TqKvdau5JdhUrWVq/1Bjgbr5ccXiWveK13iB9E0ubeJ37ObtF7V1f+zzMJk/tgSUGBe1 dj1Y8mOajFjL2N7mHdgeckXyxWvsmcVoq/wRRnop7A/uPMf2F5SfP+M2IFqoyXd21vsN G51zUakN9BnZ6B9TlMMeN6AGpHsl5MhzGKOfm+sMvC4egljUfWE+qTWM0Ftw9Fh6LDtu TRmGQ+aDMI3z+xJW8hxHcfxCy5ZA4KO59K9WtuU5kB6AF8GjK1bNWAIkjx4sXuIlavX8 tiKw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=5kOYueUK0kPfwRXMnuMB7CxzXwrggDpW7Nff97eecNw=; b=lwDExPutC4Ge9VtYAJVy/zaa5cJ8W0Gd8W4k9Mgv3shJXITEFN3QYQqVsx+6OAB9mP b3XKhF5j72cw8qtu9FCIdxT2mfTbKAtCF5xBnG0JaEmktKxd7LAWtZgXeDUV10a5bcfL Iiz4rswBuqqBdV8SXysy83q/MMHFYH4N9VV3x3tSiVUTY2PpaptVwNOYrVNXKFb+Hdh+ Y+zAN1DKHqDy3bPNY2RXfllR2wQ2GlngNxW+wVdDUCuAQAN9L+ZJxKwJ9Yr2RVdxFDrU 0fO0EcEWjPZO1gbcJdPDEom3CalAmyrni5g8QY7l3Ee2XDON/zkjHmgUlooZW93qIqg9 cZ6w== X-Gm-Message-State: AOAM53207Y91+7+iomG1AOl1BUyM5askwNlWAYYUn2wYPqdEyGWgoiBV TeBFiTEBUMqLF3h3M9689kP8AUVR14o= X-Google-Smtp-Source: ABdhPJz7ah803iyiXhw53j6dWw9qwOArBXi5yDfw1G7bvdSPPskXr3Lt5yeKdJ/Z2hIjOXbFj0eFYA== X-Received: by 2002:a19:4bc8:: with SMTP id y191mr11510107lfa.491.1600421444704; Fri, 18 Sep 2020 02:30:44 -0700 (PDT) Received: from muffinmac ([91.206.110.141]) by smtp.gmail.com with ESMTPSA id 18sm481740lfz.141.2020.09.18.02.30.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 18 Sep 2020 02:30:43 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> Date: Fri, 18 Sep 2020 12:30:42 +0300 In-Reply-To: <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> (Dmitry Gutov's message of "Fri, 18 Sep 2020 12:00:12 +0300") Message-ID: <m2zh5nqvnh.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Dmitry Gutov <dgutov@HIDDEN> writes: > On 17.09.2020 10:29, Andrii Kolomoiets wrote: >> Debugger entered--Lisp error: (file-missing "Cannot open load file" "No such file or directory" "vc-nil") >> require(vc-nil) >> vc-find-backend-function(nil make-version-backups-p) >> vc-call-backend(nil make-version-backups-p "/private/tmp/gittest/") >> vc-version-backup-file("/private/tmp/gittest/") >> vc-revert-file("/private/tmp/gittest/") >> vc-revert() >> funcall-interactively(vc-revert) >> call-interactively(vc-revert nil nil) >> command-execute(vc-revert) >> At least for `hg` and `git` backends. Maybe because `vc-registered` >> for >> repo root is nil. > > I don't think we support vc-revrt on directories, repo root or not. Calling `vc-git-revert` or `vc-hg-revert` directly with repo root or any directory within repo works fine.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 18 Sep 2020 09:00:23 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Fri Sep 18 05:00:23 2020 Received: from localhost ([127.0.0.1]:40843 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kJCFj-00024G-H2 for submit <at> debbugs.gnu.org; Fri, 18 Sep 2020 05:00:23 -0400 Received: from mail-lf1-f48.google.com ([209.85.167.48]:40160) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1kJCFg-00023y-JI for 43464 <at> debbugs.gnu.org; Fri, 18 Sep 2020 05:00:21 -0400 Received: by mail-lf1-f48.google.com with SMTP id m5so5300266lfp.7 for <43464 <at> debbugs.gnu.org>; Fri, 18 Sep 2020 02:00:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=sOYbsfRdafQjmQ1Dns0qDVjk1SIfzHLcZbBS0g8vyY0=; b=a54bAkjJ+ZRm4WNnZuBjKMRekaqsw49gYMbJfVQbyKfnfFASbcX7bmB1F31Us6eLB9 QD1ANiic4BpnjnmQBpbWKtFtJUobYgaPYFB3WRr2Q00uxSyJHuNACZ2kpMRbtZDqLgEv YKiq7lzvkn3EkwNXYavHx6TMkfR2ILpm6EG+ey+M/cJtSF/voXDpHIjGhe6Q5M5VoOFw /OV1E3QhURKZCLh1CCyojGJ53we7OvCAViI0Zj/PR3uJTYBy5BvaLLT5vCODzSMghnEO sIRGOVtRH7NB9iVbv78pmBhCjMEWVZ8NUzWbVwFutnH5c7e0qLmh6pPR21qJdXxMPpIJ E3fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=sOYbsfRdafQjmQ1Dns0qDVjk1SIfzHLcZbBS0g8vyY0=; b=EY2zp5WsmQv+COBIPqObFGShudSHyVB/uUIKagGWqXIKCZ/8HBjfortFoROYJeDPDY eSDAZGJ853RDL+fGAZjoZIZUCfDSbVMeJrouTN7ZLbJx8P+jCMHpcW9UYBRJ5RVwqNWv mNW44UZ3hwnCuOLCNGC/cxQzGib9p4rJmqm3m72R8BGLGm27Ty092wLgzlNFkCcyXs/6 eEqWzdKscAeiyT/ijFhd4gByTgZq/1WuyPyJJxFDwuXKFpLFcGuWs9+hFaheyL9oT0q2 MatKUuZrD+7lZT2oUe9Z0QUZLe07MfGel1c8EZz/ittLjkl/TGJrC+/gEW2D2ABF3gQ1 KUaw== X-Gm-Message-State: AOAM533U3q8ZMU8GIkFYINmj8iRyjIZevNHGAXIdze0Sjprj/YJ3v+G5 wleNY/PKFdjd02tq5tW0iVJT2bQy4as= X-Google-Smtp-Source: ABdhPJyR0ZWe/C9J9u+bHTwOBf/GPvA7Vk7lF69MnJ43mAeRwWEJwtXSiZ7EA3hwkoSqREBMRV4l8A== X-Received: by 2002:ac2:4148:: with SMTP id c8mr10003047lfi.278.1600419614208; Fri, 18 Sep 2020 02:00:14 -0700 (PDT) Received: from [192.168.0.104] ([94.229.108.16]) by smtp.googlemail.com with ESMTPSA id p27sm450131lfo.272.2020.09.18.02.00.13 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 18 Sep 2020 02:00:13 -0700 (PDT) Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root To: Andrii Kolomoiets <andreyk.mad@HIDDEN>, 43464 <at> debbugs.gnu.org References: <m2lfh8kgjf.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <af8b2cee-cd7f-f5a8-32ba-1cd07c97910d@HIDDEN> Date: Fri, 18 Sep 2020 12:00:12 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <m2lfh8kgjf.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 43464 X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.5 (/) On 17.09.2020 10:29, Andrii Kolomoiets wrote: > Debugger entered--Lisp error: (file-missing "Cannot open load file" "No such file or directory" "vc-nil") > require(vc-nil) > vc-find-backend-function(nil make-version-backups-p) > vc-call-backend(nil make-version-backups-p "/private/tmp/gittest/") > vc-version-backup-file("/private/tmp/gittest/") > vc-revert-file("/private/tmp/gittest/") > vc-revert() > funcall-interactively(vc-revert) > call-interactively(vc-revert nil nil) > command-execute(vc-revert) > > At least for `hg` and `git` backends. Maybe because `vc-registered` for > repo root is nil. I don't think we support vc-revrt on directories, repo root or not.
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Lars Ingebrigtsen <larsi@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Received: (at 43464) by debbugs.gnu.org; 17 Sep 2020 16:11:10 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Sep 17 12:11:10 2020 Received: from localhost ([127.0.0.1]:38785 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kIwV4-0003Kk-AW for submit <at> debbugs.gnu.org; Thu, 17 Sep 2020 12:11:10 -0400 Received: from quimby.gnus.org ([95.216.78.240]:42690) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <larsi@HIDDEN>) id 1kIwV1-0003KO-Ri for 43464 <at> debbugs.gnu.org; Thu, 17 Sep 2020 12:11:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=hvOP4YPhrLb5cglH9bfrcsxqd2amENGSuowtwDXQbaM=; b=AuZB2nVidjG3FtE5ZXO4esOFYu TzJGXHk0gR5gw3FOV6Wp93cCzn6YsnHzILggkstWd035w9E/tQclb5V2CiNlAzz0ydeOUBFcCaVpi gBICxPDr5trQrZZI+O7E2sOyd180x5Us8boUiIA94XF1zLUdbSCDjVFI7kspslFGRfls=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <larsi@HIDDEN>) id 1kIwUt-0002J9-3I; Thu, 17 Sep 2020 18:11:01 +0200 From: Lars Ingebrigtsen <larsi@HIDDEN> To: Andrii Kolomoiets <andreyk.mad@HIDDEN> Subject: Re: bug#43464: 28.0.50; vc: Error calling vc-revert for repo root References: <m2lfh8kgjf.fsf@HIDDEN> X-Now-Playing: Noveller's _Arrow_: "Thorns" Date: Thu, 17 Sep 2020 18:10:57 +0200 In-Reply-To: <m2lfh8kgjf.fsf@HIDDEN> (Andrii Kolomoiets's message of "Thu, 17 Sep 2020 10:29:08 +0300") Message-ID: <87o8m4o032.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Andrii Kolomoiets <andreyk.mad@HIDDEN> writes: > 1. Create repo with modified file: > mkdir gittest > cd gittest > git init > touch foo.txt > git add . > git commit -m "foo" > echo "bar" > foo.txt > 2. emacs -Q > 3. C-x v d > 4. C-x v u > 5. Confi [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 43464 Cc: 43464 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Andrii Kolomoiets <andreyk.mad@HIDDEN> writes: > 1. Create repo with modified file: > mkdir gittest > cd gittest > git init > touch foo.txt > git add . > git commit -m "foo" > echo "bar" > foo.txt > 2. emacs -Q > 3. C-x v d > 4. C-x v u > 5. Confirm discarding changes > > Debugger entered--Lisp error: (file-missing "Cannot open load file" "No such file or directory" "vc-nil") > require(vc-nil) I get the same error... but if I move point down to the foo.txt line, then I get no error. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no
bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 17 Sep 2020 07:29:25 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Thu Sep 17 03:29:25 2020 Received: from localhost ([127.0.0.1]:37245 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1kIoM8-0002L1-Og for submit <at> debbugs.gnu.org; Thu, 17 Sep 2020 03:29:25 -0400 Received: from lists.gnu.org ([209.51.188.17]:56388) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <andreyk.mad@HIDDEN>) id 1kIoM6-0002Ks-Di for submit <at> debbugs.gnu.org; Thu, 17 Sep 2020 03:29:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46384) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <andreyk.mad@HIDDEN>) id 1kIoM6-0002VU-6t for bug-gnu-emacs@HIDDEN; Thu, 17 Sep 2020 03:29:22 -0400 Received: from mail-lj1-x234.google.com ([2a00:1450:4864:20::234]:42945) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <andreyk.mad@HIDDEN>) id 1kIoM4-0002P2-JX for bug-gnu-emacs@HIDDEN; Thu, 17 Sep 2020 03:29:21 -0400 Received: by mail-lj1-x234.google.com with SMTP id k25so1114388ljg.9 for <bug-gnu-emacs@HIDDEN>; Thu, 17 Sep 2020 00:29:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version; bh=WddFo1oNUNlnq4ZFObiZS/iCfUCxBHoSyo2VmIYGhxo=; b=F61uNcL5iktTUZ9ZrNyOiBBoNzj4MCTjArzRJmIqL6lT/5vG4utk/he8e9uHQPQRZz FEVb6JPnFM1tsIrG6BHZiUBjhoO9C3F85r9j5rmLTbDoRbH4S53uShTsRfdLPa5HvDBP w4ClPkyN4J68Az6tAk/5BL65GcwuSzXR7QVHJ3CwjBqxGyoWTIb+J9vMEKSb90ZLkizD KTPCJf5ihWh71JqpFsAMQfYrQzA8DrcovmABq6jUKai4J0p12YGAymSIgx4R/mir8hET 5oppWCq+ucuGakOsAh2+evB9ta7cJjnwU9aovKao7jZHZY4r5icz7fNmMG1Kgp9jUe1M xwqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=WddFo1oNUNlnq4ZFObiZS/iCfUCxBHoSyo2VmIYGhxo=; b=pHhvPSdZmN8UFEg89ZXSDpYt4bZMsNIAMElhFNZCx08zZyKaTnvgvVEaJM79suyYtF lmn4Fug/RTwRnokIyp4ZHq69THLsHyeXrGacFiJpsw56gSCN0sfra5F3UF9XtqUyauDf etlGSFVXqP8CfEeQJuA6oL5F3XW21JbO61C8dm6DN22A1dMmr/6suh1uw5s5vUEtOq+9 asYYem8HZwBeiJvV92ySpp+KX08gbhX+H8M/Z3Rl6/1b/45CxCjfYUhMQTXBLX0qkQeP rPKVVKU/JHvgPddL/EslyP1OYhihNy07YlwVoh6/aRtcLSZDEXagF26jnU+NpmnUeA2l C3WQ== X-Gm-Message-State: AOAM5319J0Ym1ll4vvbeo4xqi3dSZkqUqOGVH8Ht/+98dPq2kYGhh3z7 38epDnG6X/GGaHatwXrn/xCS7dcuzYs= X-Google-Smtp-Source: ABdhPJwz/w3iBuLyIzmfqVlu4BCfF7BlGggytKLxsbw5RK5t4BIuB8+8GzwfIKsuYsIBwcmp6xFxNg== X-Received: by 2002:a05:651c:1056:: with SMTP id x22mr10679230ljm.81.1600327758217; Thu, 17 Sep 2020 00:29:18 -0700 (PDT) Received: from muffinmac ([91.206.110.141]) by smtp.gmail.com with ESMTPSA id n3sm5817340ljj.59.2020.09.17.00.29.16 for <bug-gnu-emacs@HIDDEN> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Sep 2020 00:29:17 -0700 (PDT) From: Andrii Kolomoiets <andreyk.mad@HIDDEN> To: bug-gnu-emacs@HIDDEN Subject: 28.0.50; vc: Error calling vc-revert for repo root Date: Thu, 17 Sep 2020 10:29:08 +0300 Message-ID: <m2lfh8kgjf.fsf@HIDDEN> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::234; envelope-from=andreyk.mad@HIDDEN; helo=mail-lj1-x234.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.7 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) 1. Create repo with modified file: mkdir gittest cd gittest git init touch foo.txt git add . git commit -m "foo" echo "bar" > foo.txt 2. emacs -Q 3. C-x v d 4. C-x v u 5. Confirm discarding changes Debugger entered--Lisp error: (file-missing "Cannot open load file" "No such file or directory" "vc-nil") require(vc-nil) vc-find-backend-function(nil make-version-backups-p) vc-call-backend(nil make-version-backups-p "/private/tmp/gittest/") vc-version-backup-file("/private/tmp/gittest/") vc-revert-file("/private/tmp/gittest/") vc-revert() funcall-interactively(vc-revert) call-interactively(vc-revert nil nil) command-execute(vc-revert) At least for `hg` and `git` backends. Maybe because `vc-registered` for repo root is nil. Same error in Emacs 26 and 27.
Andrii Kolomoiets <andreyk.mad@HIDDEN>
:bug-gnu-emacs@HIDDEN
.
Full text available.bug-gnu-emacs@HIDDEN
:bug#43464
; Package emacs
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.