GNU bug report logs - #63891
29.0.91; customize-save-variable should not save all variables if a custom file exists

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Jimmy Yuen Ho Wong <wyuenho@HIDDEN>; dated Sun, 4 Jun 2023 12:37:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 28 Oct 2023 09:58:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Oct 28 05:58:47 2023
Received: from localhost ([127.0.0.1]:37789 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1qwg5e-0003H9-He
	for submit <at> debbugs.gnu.org; Sat, 28 Oct 2023 05:58:46 -0400
Received: from mail-yb1-xb2e.google.com ([2607:f8b0:4864:20::b2e]:60565)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maurooaranda@HIDDEN>) id 1qwg5b-0003Gp-Hn
 for 63891 <at> debbugs.gnu.org; Sat, 28 Oct 2023 05:58:45 -0400
Received: by mail-yb1-xb2e.google.com with SMTP id
 3f1490d57ef6-da077db5145so2024368276.0
 for <63891 <at> debbugs.gnu.org>; Sat, 28 Oct 2023 02:58:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1698487086; x=1699091886; darn=debbugs.gnu.org;
 h=content-transfer-encoding:in-reply-to:from:references:cc:to
 :content-language:subject:user-agent:mime-version:date:message-id
 :from:to:cc:subject:date:message-id:reply-to;
 bh=PxO10TsZh+KRZTdazOXptOAfr1AJ7KsfCDWLT0Z5IYU=;
 b=fkR1tJLnKtPrvBIKKtIDJSfMvOcNi+EmhTaooCybZZ1WgJXLTRTTjlxt7+Sqxwl4EV
 y1bwZoLsGAxM+NFiQnTN9/g9nEYIatyFBDgh3dVxqTUfUztXqPb7uMH6xdHQvNg90RU1
 cScv96W/VD7hUCcgGqPZB+CQsQyXFTKL6Jw5bHZGr77+lQLzNKmz/B8Zb4aLeklF19T2
 zppwx7Be1Gl7MXV4lLfKt+KVol25eidc8ZIhdi+/Lxs5yWe2ac3leNHAUuFEYR/74UA8
 T0i4no85/yd0xC6Ht7bx4wK82ktdGYRjJ7BdxPzK5GwAP/wAx8uzO+RSpVA8LzuoxQf1
 tnUw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1698487086; x=1699091886;
 h=content-transfer-encoding:in-reply-to:from:references:cc:to
 :content-language:subject:user-agent:mime-version:date:message-id
 :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=PxO10TsZh+KRZTdazOXptOAfr1AJ7KsfCDWLT0Z5IYU=;
 b=DfNhp1PsTypIPW76Tz78aZ0hYHB8nTfDUKOwmQ4G9c72wnUuLGarSlIs8h1nQVsKWm
 WopAixMgSgnYUaOKTPXjDHNol0LcNB68mKNIBuKT3N4RSQyOpgVxtEHI7AYbARZFxVfL
 sH6KJgRfGukTY1XiV6QSCrk1GJU+0pztAEgKYiqIVCuHOxI4YIjjwOIbx95s0Whp98hM
 KLWwBsf4bGtc/1rJDwkLeRibMInktSJ2pJICqUxfH5IWvUOI+Ptykc2vsJBtN0RsMjrS
 jAu3uJKt9l5UhcIqEjXriF6PEdml+367+E871aIk9XAPv66GBxSoqoPqfzJGoUH7ikQd
 9bJg==
X-Gm-Message-State: AOJu0YyD+KWEcBKFw2iE6RiaNZTW0/KVrScXwvZJfP/G92PrabAsmQ48
 lUCFz1cJwXMgqJlDBRxewBg=
X-Google-Smtp-Source: AGHT+IECunCo5O2iZIxnExXGURArzjLOCX+A4vdYcXz7B6dmDKsGmep3DgLwSejnXsvAOnwW6ceu+A==
X-Received: by 2002:a5b:9:0:b0:d9b:76c3:4567 with SMTP id
 a9-20020a5b0009000000b00d9b76c34567mr5221178ybp.55.1698487085919; 
 Sat, 28 Oct 2023 02:58:05 -0700 (PDT)
Received: from [192.168.0.234] ([152.168.142.156])
 by smtp.gmail.com with ESMTPSA id
 j205-20020a2523d6000000b00da05d771097sm1512796ybj.22.2023.10.28.02.58.04
 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
 Sat, 28 Oct 2023 02:58:05 -0700 (PDT)
Message-ID: <0ec5d535-c4e5-401f-8db7-fc4eb54f8517@HIDDEN>
Date: Sat, 28 Oct 2023 06:58:02 -0300
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
Content-Language: en-US
To: Michael Albinus <michael.albinus@HIDDEN>
References: <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@HIDDEN>
 <1f269cb9-2cdf-4499-b68d-756d27648673@HIDDEN> <874jicgu5w.fsf@HIDDEN>
From: Mauro Aranda <maurooaranda@HIDDEN>
In-Reply-To: <874jicgu5w.fsf@HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: Eli Zaretskii <eliz@HIDDEN>, wyuenho@HIDDEN, 63891 <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 (-)

Hi Michael,

I looked at this more deeply, and I think I still don't understand
what's being asked of Custom in this use case.

First, let me just say that I'm aware of some problems with the
custom-save-all approach to modify the custom-file.  It was reported in
Bug#14150, but, while a different approach to fix Bug#14150 could also
solve this bug, I'm still not sure if the use case in files-x.el is a
supported one.

Both functions, connection-local-set-profile-variables and
connection-local-set-profiles modify 2 defcustoms, and want to tell
Custom that a change has happened.  The usual way to do that is to call
customize-set-variable, because the assumption is that the user used
some command provided by a package to modify the option.  And the
setting lasts for the session, of course.  But the surprise in Bug#62106
was that the users weren't requesting these changes in the options.  It
was done without a choice.

So, the code was changed to use custom-set-variables, which is used in
the custom-file and which means all the settings here should persist
from session to session.  So, in addition to modifying the user option
without a choice, the code then said that these modifications should be
saved.  That's even worse, which should show that custom-set-variables
is just the wrong tool here.  Of course, there's the workaround of
resetting saved-value to nil if possible.  But that just means that if
the user has a saved setting, he/she could possibly end up with all
settings added by a package too.  Of course, if Custom had other
approach for saving the settings, that would not happen, but it wouldn't
happen if the code weren't lying to Custom either.  And please note that
a similar workaround could be added if the code used
customize-set-variable still.

But here is my first question, if packages are going to be changing this
2 options without asking the user about it, why do the packages need to
lie to Custom saying that the user asked for that? Why don't just setq,
add-to-list or modify it some other way? At least that way Custom would
know the truth, the setting was changed outside of Customize.

That's why I don't understand what is the expectation about Custom here
(apart from being less naive when saving the custom-file).  The code is
modifying a user option and tells Custom that it was upon the user
request, when in fact it hasn't.

Finally, have you considered the approach of having the user option plus
another variable which packages should modify when desired? Then the
code could merge the user settings with the package settings.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 27 Oct 2023 15:45:03 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Oct 27 11:45:03 2023
Received: from localhost ([127.0.0.1]:36890 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1qwP1C-0002q0-RB
	for submit <at> debbugs.gnu.org; Fri, 27 Oct 2023 11:45:03 -0400
Received: from mail-oo1-xc36.google.com ([2607:f8b0:4864:20::c36]:50297)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maurooaranda@HIDDEN>) id 1qwP1A-0002pC-FB
 for 63891 <at> debbugs.gnu.org; Fri, 27 Oct 2023 11:45:01 -0400
Received: by mail-oo1-xc36.google.com with SMTP id
 006d021491bc7-586753b0ab0so1212238eaf.0
 for <63891 <at> debbugs.gnu.org>; Fri, 27 Oct 2023 08:44:28 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1698421463; x=1699026263; darn=debbugs.gnu.org;
 h=content-transfer-encoding:in-reply-to:from:references:cc:to
 :content-language:subject:user-agent:mime-version:date:message-id
 :from:to:cc:subject:date:message-id:reply-to;
 bh=w7hBqkrfx7xKYJLcQegBMNfZIxUCQOiFyfkCmqni+wc=;
 b=lhTviZwoPPiFkbZP3SPKQnq7IEw4LHLW1tluP7AP8s/qM7Hgajy5ikecZivIg+epaH
 wiO8mm7vkLu2AZE9lyi0vdhXd9QoiwE6l8RYGpP9C4RotBxKnxCda5Z+HJpb7idEpA21
 TrYON9gxsAu/1gusdMv0x/hAI2fam8hInCaSEdPYT2pqJ65NzcthjZ1pIRhVoXa0pCX/
 7s5H71DdsQjifcX/LxVCyk7WZWDdC85OsjPOEJhnkLVp/bl0g6X0LGwrQrTvska1uFMF
 YZlk9mJhjK8q9qw5AzOUwtqAzGvZ/X120MFtfzlT2B/xvAdn44sR/zAZ/Mo4j+56AWHe
 npZg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1698421463; x=1699026263;
 h=content-transfer-encoding:in-reply-to:from:references:cc:to
 :content-language:subject:user-agent:mime-version:date:message-id
 :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=w7hBqkrfx7xKYJLcQegBMNfZIxUCQOiFyfkCmqni+wc=;
 b=EFysZojxPJEtwxN6tEb3nKP0ZLAEUEJ2hH8miJnvZmqu5qfzXdHl9MVu8bJMB9U/Oc
 4m8zeLxq41709fET1rP6tT2rFLsi/jc8+QK6bba8mjMeUiKQlhJnyIyxfwIAHcFuLZsY
 gd1k8eOA2iPoG7WaPQlns/W9yKPquTcca6CfwbX4jbkSwxt3BkXcNHZvQD9H4xTyJM4w
 aNx5FWmr+COj58lCvUOqAJs3tuYgPVPqU9RPxKYTsbfWeKLaafeJgw/9rNuedK5FQMrs
 xJzQ6iYjRkOJJaLhPpJ35ZQtM8Rgu/bi8Ytd+ekuuE7JOpUxUteASu+D1sQUGd48Borc
 CFcg==
X-Gm-Message-State: AOJu0Yy2oy/fERyltKbsV/biSIMcpCJuRr2bFjEVE/ptlqEiZzKXqBvN
 TBKHY7Gzdg+zTn49xH2GjlQ=
X-Google-Smtp-Source: AGHT+IEoZ/NGY+qey76x2UsWCrE1hlnGQAIBV4973f+ufKIlKWLpcl8h0t9SHsMPAITImC0leWLviw==
X-Received: by 2002:a05:6358:787:b0:168:e18d:5ba8 with SMTP id
 n7-20020a056358078700b00168e18d5ba8mr3517677rwj.0.1698421462908; 
 Fri, 27 Oct 2023 08:44:22 -0700 (PDT)
Received: from [192.168.0.234] ([152.168.142.156])
 by smtp.gmail.com with ESMTPSA id
 f17-20020a637551000000b005b9083b81f0sm1275745pgn.36.2023.10.27.08.44.20
 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
 Fri, 27 Oct 2023 08:44:21 -0700 (PDT)
Message-ID: <61df90f1-c097-42cf-97c6-1186e49d2f88@HIDDEN>
Date: Fri, 27 Oct 2023 12:44:17 -0300
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
Content-Language: en-US
To: Michael Albinus <michael.albinus@HIDDEN>
References: <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@HIDDEN>
 <1f269cb9-2cdf-4499-b68d-756d27648673@HIDDEN> <874jicgu5w.fsf@HIDDEN>
From: Mauro Aranda <maurooaranda@HIDDEN>
In-Reply-To: <874jicgu5w.fsf@HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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 (-)

On 27/10/23 08:51, Michael Albinus wrote:
 > Mauro Aranda <maurooaranda@HIDDEN> writes:
 >
 > Hi Mauro,
 >
 >>> custom-set-variables sets the saved-value property of the
 >>> variables. This is what is called in connection-local-set-profiles and
 >>> connection-local-set-profile-variables.
 >>
 >> Why do those functions use custom-set-variables, instead of
 >> customize-set-variable?
 >
 > This is what we have used before. Due to bug#62106 we cannot use
 > customize-set-variable.
 >

I see, thanks.  I'll study this more carefully.






Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 27 Oct 2023 11:52:23 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Oct 27 07:52:23 2023
Received: from localhost ([127.0.0.1]:35274 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1qwLO3-0001e7-0M
	for submit <at> debbugs.gnu.org; Fri, 27 Oct 2023 07:52:23 -0400
Received: from mout.gmx.net ([212.227.15.19]:44331)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <michael.albinus@HIDDEN>) id 1qwLNx-0001do-Vy
 for 63891 <at> debbugs.gnu.org; Fri, 27 Oct 2023 07:52:21 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417;
 t=1698407499; x=1699012299; i=michael.albinus@HIDDEN;
 bh=TCfxcz/3w1H3E8VhjbFN5Iv68HARjHhVo36y8x00qEM=;
 h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:
 Date;
 b=tKRnR5pElc7vjcetoyWdw9vnvfxp0i4Rc/9V7u/SuW+xOuBPRVjYNPdHVeGZAI+B
 3apwD4DHOUGKsELreZlu01B+b6PvygmHJxXRRiSb201AKm+inpety6gyo7ajEW9B/
 NJ9tPTkVhgTP7IFakPy+p+NCkHqzHAipe+1xmFJqDxOVU49IdNQ+6ht9D+Cxj9xcx
 aXTaRMyNJ6klh1x8zv4qBzAHYpm5rnx2LVD/b0NgnQWDgKKYuGqP9+ptLzSPVhP4F
 YS0XXzeqyzDO3IbBxxqPpD7w5He6TqfBZbuQUYpWQR7dnjHWm3BWYLaPCXECAn1Oq
 tiATWbChqJUh/4kxfg==
X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a
Received: from gandalf.gmx.de ([185.89.39.30]) by mail.gmx.net (mrgmx004
 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MgvvT-1rPeWE2wmb-00hQ6X; Fri, 27
 Oct 2023 13:51:39 +0200
From: Michael Albinus <michael.albinus@HIDDEN>
To: Mauro Aranda <maurooaranda@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
In-Reply-To: <1f269cb9-2cdf-4499-b68d-756d27648673@HIDDEN> (Mauro Aranda's
 message of "Fri, 27 Oct 2023 07:57:52 -0300")
References: <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@HIDDEN>
 <1f269cb9-2cdf-4499-b68d-756d27648673@HIDDEN>
Date: Fri, 27 Oct 2023 13:51:39 +0200
Message-ID: <874jicgu5w.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain
X-Provags-ID: V03:K1:MGqZILzx23KpzU7JMO+LzPKUYPTI+WFzRk01LdfLLI2pIcOmDgk
 OD7Ify6KaFadpyJZC9rp7RpMY10YTirRHg3l2U9aZJq++rM+erc4k+jZTgyUxAHScog7Z65
 8doMyyJAy5acyHOKjg0agsKIbGLM4Lzaiy8QJW5jvm55QSoaW7CsMqtfLHX0MeoyGkE1Tm7
 kigiIx19W3EZ9rgVnYEuQ==
X-Spam-Flag: NO
UI-OutboundReport: notjunk:1;M01:P0:vnvOlLpZhE0=;4NWDn6QTeLXjhQ9lcOwv/z5utMf
 q0p9vKnh/ba1Z15ksXTNubqxytrHR/MuzuwY2/2tzkx+k1GC2TaPp/4/KA5Y8T2DPRrStJXQy
 yAa3S3Ha5Eah89aCIxt3fhpDaHtzgbMfJOqVametkTGTKrWsP5KYTqW5bwgkx+Pbb8fASOaa1
 bldz361H6lAsqMoCq33ST9uP/LgaqUTlBV33709OhgS4Y4POLw3Oa30PPu1yexQK0N74LOZ+E
 nHiI2wk7lbEtgmpmbO0a4hj6T0wnZ4W/eukNyetzZkMeRSb9KKCbxE0pqA8eQnNVaOzguaybK
 ukWjlm+w+zm7MeBoiD0krIFf5/tamLhk2eymb0JU2zKPpLPiNiwgbNyVU6utBqs7aYmhk9aU7
 NLkW+3lyoujSkBonorSHeSooleHciO5UeVhOeo7B5uUbGU50T5zd/U9nJBRiicfvSDv0W4HJE
 IounM21Y/bsFQ8L32dPAegcPTEhEgS2g2UgOu7RUIHA5ZU5LnArW00LKUE9VsK0O3OZpdPUQo
 q38L/mFdQoPsJslIMjiX9Ree+DRfJku7q4l3REPvvVXiEVoH1BT8ojsB+C0PuX8ufS059upHq
 YsJQzOU1O0U4CAPupTYrGksvO8j6vIwA0RPoXA6WCso3wtohdMuAM8y53uuPmyHJIGJVK/Cxo
 iNvnRaHT+NnC2dkAYUZLNDMUdIJ+c306SN6iD4RO4XhDaO0DVmrxU5WUkLLMXflKxNUNo4q8i
 6XQ680zkiXzE4l8PHGfDqg0Hy4e3UBjKd8ad9J0t3LLmAsasNv1qHAr1lhiCCHLWsQswu16YD
 Ie
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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.7 (-)

Mauro Aranda <maurooaranda@HIDDEN> writes:

Hi Mauro,

>> custom-set-variables sets the saved-value property of the
>> variables. This is what is called in connection-local-set-profiles and
>> connection-local-set-profile-variables.
>
> Why do those functions use custom-set-variables, instead of
> customize-set-variable?

This is what we have used before. Due to bug#62106 we cannot use
customize-set-variable.

Best regards, Michael.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 27 Oct 2023 10:58:35 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Oct 27 06:58:35 2023
Received: from localhost ([127.0.0.1]:35229 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1qwKXz-00061x-DT
	for submit <at> debbugs.gnu.org; Fri, 27 Oct 2023 06:58:35 -0400
Received: from mail-pl1-x62f.google.com ([2607:f8b0:4864:20::62f]:43022)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <maurooaranda@HIDDEN>) id 1qwKXx-00061h-DW
 for 63891 <at> debbugs.gnu.org; Fri, 27 Oct 2023 06:58:34 -0400
Received: by mail-pl1-x62f.google.com with SMTP id
 d9443c01a7336-1cc131e52f1so10079915ad.0
 for <63891 <at> debbugs.gnu.org>; Fri, 27 Oct 2023 03:58:01 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1698404276; x=1699009076; darn=debbugs.gnu.org;
 h=content-transfer-encoding:in-reply-to:cc:references:to:from
 :content-language:subject:user-agent:mime-version:date:message-id
 :from:to:cc:subject:date:message-id:reply-to;
 bh=yIi9N8PkdVcDqytQ/jaMMYLoR5Z3CUhv3ISTjTJRQ1I=;
 b=RUYa/5eoOEkuZ7x8QR58f+Qjm+yhPdYrHNjFLM+iryh8lbe1NPsQLOF60T3bFmJehP
 FMPzdkACm+2lsN+dUUH4NQqJqL69tP5uHEe05jJWHRV2RdvAHG5SRrQlfutVP5o93Moi
 qxWNqTpsSqn+ZcrcyduZLs6pJ6vrw588xzgj1B/B5ObiSsS8bS7Riz8aSm1zK9oqN0FA
 MFFvrs3/BVnp1SOnXXxOrDaoly2T+BESkP8eRuQUzisKEkO1JGbOj79fOtwor13bvW9B
 mLWuPlNIwSSh6rSWloFNyLZuKhClwByVwz/7OpHUwMxZncjm62zdFwonSIGBgvsHD1Y1
 N6eA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1698404276; x=1699009076;
 h=content-transfer-encoding:in-reply-to:cc:references:to:from
 :content-language:subject:user-agent:mime-version:date:message-id
 :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=yIi9N8PkdVcDqytQ/jaMMYLoR5Z3CUhv3ISTjTJRQ1I=;
 b=n4QxY5ZSWiKwd+yG5cazriGJclq/EjVS6Xzs5ZeFByzeM+9hLPIjFtODfgB/gx9Ock
 mWeAPgEjPYHCXY8qoGi+AdUFmr4JL2Yb0bt+hSknlxgN6ZTBq3/YxtJH7oM7cuzdQXKQ
 Fci9+UfGtfahlQhUsh+meGz994YRg8NXKRHkPvwPWqgNE0p/pTJd0ygIXBjMP6qag/9T
 H2vd+HBzuSneXDDBGr2CxIpjTBOPjz10sH4Yvw4h1ZMFBK12uNVciqs4o4pQQQ4E3o+R
 kf6YUGoZxGuIy/ux/K5kxq2pxxboTpKdVYZEQgOF3Hs12pIU9Yuveg9I31+TAp6pUUdQ
 2JKg==
X-Gm-Message-State: AOJu0YwaFgekOKG29Vf+GhHZ88N7p0pIXOzkLEl1Ek8Ucdc5slfUTojR
 37nF0GwbaYOOzL13QbjAG14=
X-Google-Smtp-Source: AGHT+IGmWaYnBzyukbgoAreFTlD3h91NHiABnKs4YmI0E+1yhq9TA8cQFlghqLH+RIg/6LaLRS3mgg==
X-Received: by 2002:a17:90a:5d95:b0:27f:e955:5682 with SMTP id
 t21-20020a17090a5d9500b0027fe9555682mr3056714pji.3.1698404276209; 
 Fri, 27 Oct 2023 03:57:56 -0700 (PDT)
Received: from [192.168.0.234] ([152.168.142.156])
 by smtp.gmail.com with ESMTPSA id
 27-20020a17090a195b00b0027fee011cebsm1095299pjh.10.2023.10.27.03.57.54
 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
 Fri, 27 Oct 2023 03:57:55 -0700 (PDT)
Message-ID: <1f269cb9-2cdf-4499-b68d-756d27648673@HIDDEN>
Date: Fri, 27 Oct 2023 07:57:52 -0300
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
Content-Language: en-US
From: Mauro Aranda <maurooaranda@HIDDEN>
To: Michael Albinus <michael.albinus@HIDDEN>
References: <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@HIDDEN>
In-Reply-To: <ae449be5-9a4c-4e7e-b624-deae8a27fbbb@HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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 (-)

[Oops, resending to the right bug address]

Michael Albinus <michael.albinus@HIDDEN> writes:


 > custom-set-variables sets the saved-value property of the
 > variables. This is what is called in connection-local-set-profiles and
 > connection-local-set-profile-variables.

Why do those functions use custom-set-variables, instead of
customize-set-variable?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 6 Jun 2023 12:36:26 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jun 06 08:36:26 2023
Received: from localhost ([127.0.0.1]:51170 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q6VvF-0005bF-Tl
	for submit <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:36:26 -0400
Received: from mout.gmx.net ([212.227.15.15]:45057)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <michael.albinus@HIDDEN>) id 1q6VvC-0005aw-2U
 for 63891 <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:36:25 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de;
 s=s31663417; t=1686054975; x=1686659775; i=michael.albinus@HIDDEN;
 bh=+PSBRHwKv/1ueh38Ib4eBa0OOKWQ31YqNfS3UbwMECI=;
 h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date;
 b=nT8mU3CXp7gE/DnXxMZMZw+55J0fAiT5F1vJpHxZFM4PYUdT8XQdg3Qwa5TkxrTbKX/a2dm
 BONFXwlYCpCUZd5dlqsS71J3dcT7QE3ns8g6YoFFrRVBHUzbbgyY2xpMIzWdFisr4vtiSkRJS
 mJ9VoNgeJ43bHEeeBSowjekOrHUq5cv2ZLc+ptAPQiw0A6YYxPMchKzfGXShwNVovKh/rPOFz
 BrKr18DV9E0JYXTZbVOugzhmNwD6DhzeZWhORasq/a0zCQ9mAfzWFY/i9814MHwEMKLN1OY/U
 oGYzCgz1kR6wz2iIO5T9RPlM5sA+NrKmhEKU+aGDUOTeOWRGBIAQ==
X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a
Received: from gandalf.gmx.de ([185.89.39.13]) by mail.gmx.net (mrgmx004
 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MnaoZ-1qVe7W2YwX-00jcaG; Tue, 06
 Jun 2023 14:36:15 +0200
From: Michael Albinus <michael.albinus@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
In-Reply-To: <83mt1c3hqk.fsf@HIDDEN> (Eli Zaretskii's message of "Tue, 06 Jun
 2023 15:20:03 +0300")
References: <m24jnns8tt.fsf@HIDDEN> <83legz5qsu.fsf@HIDDEN>
 <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark> <83jzwj5pjn.fsf@HIDDEN>
 <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark> <83h6rn5mn0.fsf@HIDDEN>
 <87r0qopzot.fsf@HIDDEN> <83mt1c3hqk.fsf@HIDDEN>
Date: Tue, 06 Jun 2023 14:36:14 +0200
Message-ID: <87mt1cpy2p.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain
X-Provags-ID: V03:K1:ity8TIVWURlDbVrUNrd68+AkWVrFyo/227g2JB7Fc7XXfws5J0o
 E0KzEmR3A5ZM090cC3Q/9lZ7DQzR2RWiYR6/l/kMZgqWe75T8ZRPOAwihEa0wJ1Nyjqex6W
 QvZsbaJT21UdteUEOTWTA6K+hMLUsrh3IsmpX2QKjKxn9vrwskrNGjdZpv7PilJgQcINtSZ
 CNuJhKxVmWyB5tiYRniNw==
X-Spam-Flag: NO
UI-OutboundReport: notjunk:1;M01:P0:Dgrrm7of0rU=;I/cXuqOnB4pI5EPahBaNZhPuxUj
 0x4tjaM1F0t/YWhvLcbVJiAhbO4jZFQ4HY05sHxIHlB2pVK0bTVt89l8IlbzgEOpj2XGshNZO
 OME1Tr3nYk0gJWcuR4d24I1MFGn8DUWwteN0O62BsaOu+KipM/ISd9bLyj42YmJes/3KOVKD4
 ZbC5BjtdfYtazwl5nTAPEY4Afa3TcLMmUIDFbPyw3CQnBrkNTVtE+uEe7gW32E6RUwSy2VrIO
 iB8vX707bgO96kdTRRg3MhSB9N+UQSKfHVjrXzXLhlh90Yxal9remClw8clBDAIzIBQCE4JYp
 Qs73+Hza0IKLTBNBp/HbpzzUk66trcJT8DD0GKUmRR5Q+2fWDmUhLAyHwCIXSGtjwcG71SfDc
 GosEMNA1paI46kCQ7XB23TWU7GUqOxnpUDZOXgghcYtui4coxBwl7QUH1LpUcgrVbjrx+lneI
 yDfezZZyNaw/sR/dV9YRb6EAahmk/FbEpLfkSorIaZ92EgU/b8XKsbJBFmmyU4EUJcThqFQM8
 +SgeRz6JruCzBU72kBX523uVFbe+iJOW5L7OBwNgECQpNm1ZdX0QIdz5OxjZ7oAR/pIr40Es+
 7GHQwUoHcKW/od8lYj1kcb/8ZSqgy4PgyCmJ30RZLEW7SOBMQPv/3Gm0tjPInttrAah5Di77L
 ufaFd34k2gs6KdJhWu3nWNjMAzdYOGG5dCTSKGFpY5mvX3b5Fo6jDcgJHEVPln2Ajx/rLqcL3
 IXvDGehPPsdWhNT4xCWegxy6Egy5NSb3tn7GtjpXwJ7o8I/Vswq0CbDIWdaRcstqbkMBLEw6x
 LgiO+TqBB1240fAQetCyUTchY8emFXzbdjXcAOIxQMmoenIA2OJsUllyN7TXh8deyaFbioia0
 OYKQes2wx19pKqj3hP3MX8IAHCpFS+UiuUbWL627wG5hbOL/9QfkvsyTQ+l5DNV0R1kVBm1FR
 Tt9o3jlekwrBOD5XqeVcME3VzLc=
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 63891
Cc: wyuenho@HIDDEN, 63891 <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.7 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

Hi Eli,

>> >> No it does not saves only one variable to file, it only saves one va=
riable to file if you have only modified
>> >> one variable.
>> >
>> > That's not what I see.  I've modified several options using the
>> > menu-bar's Options menu, then typed
>> >
>> >   M-x customize-save-variable RET truncate-lines RET y
>> >
>> > and saw that only truncate-lines was written to the custom file.
>> >
>> > If you see something else, please show a complete recipe that
>> > reproduces the behavior you see.
>>
>> custom-set-variables
>
> That's a different function.  I was talking about
> customize-save-variable.

I know. I just wanted to clarify, where the saved-value of other user
options is set.

And customize-save-variable, although invoked with just one variable,
saves *all* variables with a saved-value property, IIUC.

A recipe you have asked for could be

=2D-8<---------------cut here---------------start------------->8---
(defcustom a nil
  "" :type 'boolean)

(defcustom b nil
  "" :type 'boolean)

(defcustom c nil
  "" :type 'boolean)

(custom-set-variables '(a t) '(b t))

;; Nothing happened so far in the init file.

(customize-save-variable 'c t)

;; Your init file contains then

(custom-set-variables
 ;; custom-set-variables was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 '(a t)
 '(b t)
 '(c t)
 ...)
=2D-8<---------------cut here---------------end--------------->8---

Best regards, Michael.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 6 Jun 2023 12:20:49 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jun 06 08:20:49 2023
Received: from localhost ([127.0.0.1]:51145 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q6Vg8-0005CP-RZ
	for submit <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:20:49 -0400
Received: from eggs.gnu.org ([209.51.188.92]:41604)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1q6Vg5-0005CB-OL
 for 63891 <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:20:46 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q6Vg0-0004Wk-2z; Tue, 06 Jun 2023 08:20:40 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=jkpOWz/yp7z2Tk3g5ACALon8JuQ/U5Qp+4qoQJSxfyo=; b=mUrXSjqKTU+Q
 cv3rWQSFeOYqkw5sRiGKUIIOC/Q5kDOxOzEcKnEPtuGJgJ2ofyS0lxUw5KF3V70E8zUPMmB6g8p71
 cAkQsjOEv8p/lNYj8P7rbi1LZ2xbvWvsbAUN0ka/VfrA8qJef2GwK6HZPLK0PurkWDgZhPEBHElhQ
 vTwVJwI1iDXsbzSkZj2kAwkEaO9sM0Pf6akzOEI/ua2oWczu0Vnf1mjf700/KtZc6eTgcoHgOMqJS
 DfnAo61pLteOvIqCPrXHkmDRc8h2P2LoRfbKiBaWhwxvH/IIds+Bgo1kSXp9MW0PbKekx7AdQxoA2
 qX8oJUfuC/wIiWCnDxyyGw==;
Received: from [87.69.77.57] (helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q6VfO-0006f1-57; Tue, 06 Jun 2023 08:20:10 -0400
Date: Tue, 06 Jun 2023 15:20:03 +0300
Message-Id: <83mt1c3hqk.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Michael Albinus <michael.albinus@HIDDEN>
In-Reply-To: <87r0qopzot.fsf@HIDDEN> (message from Michael Albinus on Tue, 06
 Jun 2023 14:01:22 +0200)
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
References: <m24jnns8tt.fsf@HIDDEN> <83legz5qsu.fsf@HIDDEN>
 <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark> <83jzwj5pjn.fsf@HIDDEN>
 <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark> <83h6rn5mn0.fsf@HIDDEN>
 <87r0qopzot.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 63891
Cc: wyuenho@HIDDEN, 63891 <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: -3.3 (---)

> From: Michael Albinus <michael.albinus@HIDDEN>
> Cc: Jimmy Wong <wyuenho@HIDDEN>,  63891 <at> debbugs.gnu.org
> Date: Tue, 06 Jun 2023 14:01:22 +0200
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> Hi Eli,
> 
> >> No it does not saves only one variable to file, it only saves one variable to file if you have only modified
> >> one variable.
> >
> > That's not what I see.  I've modified several options using the
> > menu-bar's Options menu, then typed
> >
> >   M-x customize-save-variable RET truncate-lines RET y
> >
> > and saw that only truncate-lines was written to the custom file.
> >
> > If you see something else, please show a complete recipe that
> > reproduces the behavior you see.
> 
> custom-set-variables

That's a different function.  I was talking about
customize-save-variable.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 6 Jun 2023 12:01:45 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jun 06 08:01:45 2023
Received: from localhost ([127.0.0.1]:51127 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q6VNU-0004kC-TC
	for submit <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:01:45 -0400
Received: from mout.gmx.net ([212.227.17.21]:49535)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <michael.albinus@HIDDEN>) id 1q6VNR-0004ju-Gl
 for 63891 <at> debbugs.gnu.org; Tue, 06 Jun 2023 08:01:30 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de;
 s=s31663417; t=1686052882; x=1686657682; i=michael.albinus@HIDDEN;
 bh=JRc6be5WmKLyRAtc7Qw8HLxoKTdnA6j99lLNdM5rttE=;
 h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date;
 b=hInMYeKEMjZKIx2zLJiW07q2BDvQ1kJ+OLnebf/gQEoCFOn7AQFVdXqQrgO91VZ5tRrRyXO
 hki8DOPiJb2evdqZ9lB3vfR+bcnhDjAfDJUyYyMVtaJhtdRW+CxfuJKihSFXwg65Ml91MIIF7
 cbW6YbQQC34TqgHVwrYPZpRYhmDWBVVm3mIXhsl56mv6Xw/Ct1Sf2O5q77v+gHjaFe3jWzi1D
 /2i9eFEpq90ZglRB6Rk+EUrLAbGZblwJ19aiTOGohnfb8hhB8IyyAV0oDwQLKG2DZAeo+MbTn
 f4JNoX75sJO+32TDHIRZn9bMwD4+XkWFtCD4LbxmZNQXpHypaSeg==
X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a
Received: from gandalf.gmx.de ([185.89.39.13]) by mail.gmx.net (mrgmx105
 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MI5QF-1prN5h390h-00FA8K; Tue, 06
 Jun 2023 14:01:22 +0200
From: Michael Albinus <michael.albinus@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save all
 variables if a custom file exists
In-Reply-To: <83h6rn5mn0.fsf@HIDDEN> (Eli Zaretskii's message of "Sun, 04 Jun
 2023 17:26:43 +0300")
References: <m24jnns8tt.fsf@HIDDEN> <83legz5qsu.fsf@HIDDEN>
 <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark> <83jzwj5pjn.fsf@HIDDEN>
 <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark> <83h6rn5mn0.fsf@HIDDEN>
Date: Tue, 06 Jun 2023 14:01:22 +0200
Message-ID: <87r0qopzot.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain
X-Provags-ID: V03:K1:80jfCr9mNcxpFEP+MIiR2cSZGl0JD3VB6LMh6hi3mbNT846Ht5K
 dRq0armnYea28ekp2pPxHQpcSGABgzpPqxiZMDL8WQ8Q4exQgjsSaWOF+k2JMVB6UATLQSS
 GaYPGUhoaHYb5iccANpLH2lYuSskHlDMXs8kT2tFoGNpzM+I0872/n4KEZoh/iM3wFuMzNj
 6cS6LYJKxO3dxMh0OmbMw==
X-Spam-Flag: NO
UI-OutboundReport: notjunk:1;M01:P0:1d9kcHsopHM=;E29+lJGegsPpTnrQJxLSjIOz6tG
 yNIHGh8Mgq648dCiVWf+DuERRRzt+QgdYo18mfFsUHQ/O7iycnFokHa99vNO+V/mB/+3jnCmy
 R/vBFIH8nKjhxecK2z9IVQc+mkOu7MHTkzEjxRycsvNwZgO6uALxyFPw9dgCmCY3xB8ZpNbC+
 kOg4M8GEsqB1Pkf+uRaNu996X72pCQs0bbSTL6wRzun7USn5pDJqQsft2ovq4QBoNXOE0B98q
 AIkl8KMDiTOX0ADxtDRLO7lzyaJt50GVYP+5K8AtJhaaBOUqCz23yxUc7PpEBPeLbEHHPS1cE
 nHXW2oEe+7V8yoO6zD36JMJ96UeA0ZfQLQmT15FQh0d/YQc5TVtDFkPJyLc3J75xPM5xSemR0
 6JIzqByzB8MZASzn9yk5BiptMfjBjfxhTOt9ufckiNdksv7jQhhkVjjiT80btOCyAF2OIqCLt
 hBvUclTS5bHZ0B4ieSI6pbxOcvlntdf+K+ckf4T0vKuHRHhUNnmBFh8adMl/AWQXivWt2+o2p
 IlNTWMnlgoBOey6e6pX6toB5Co0Ug90Sm6CHNNxRxSZT+WnyHqlTmwjICwNwspa/44S2OA9Y4
 tKEMYGVSECHJO7FHXaEMMv/fDXq8QwPRK1kcNY7eRZ54QGjTwZBheTwKmQN6FPE//5c9i3NSu
 RlD8xO9trbUrJd5UUkdPxXfgl3/zLOs/lX4vqTZwTfb2Vn6Kzo6tlw6iJ0YhBbUsdQieQbqCg
 EGtI4NAjJm7Adky8SBurj0MBirE4G6Nw3lJsB6RoXOwn4f2n6JBZE2WdmYcnHBxEOlOoWD2Ei
 xcQaki95oJ0tfZ7NHO2AGHgZCG5U0M92/gFGFy0GG3cWr88vuSWYx2v+TA1uao+DCScGYMtkf
 5y00H5GwPG+8UizXMIKs24k8i+kspGGIy1R/VKTmwnj44srEGPt3n2wl9QhU3kudhiHOEKPUr
 VCO29w==
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 63891
Cc: Jimmy Wong <wyuenho@HIDDEN>, 63891 <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.7 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

Hi Eli,

>> No it does not saves only one variable to file, it only saves one variable to file if you have only modified
>> one variable.
>
> That's not what I see.  I've modified several options using the
> menu-bar's Options menu, then typed
>
>   M-x customize-save-variable RET truncate-lines RET y
>
> and saw that only truncate-lines was written to the custom file.
>
> If you see something else, please show a complete recipe that
> reproduces the behavior you see.

custom-set-variables sets the saved-value property of the
variables. This is what is called in connection-local-set-profiles and
connection-local-set-profile-variables.

Best regards, Michael.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 16:49:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 12:49:46 2023
Received: from localhost ([127.0.0.1]:47019 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5qvK-0007Zy-Fj
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 12:49:46 -0400
Received: from mail-wm1-f51.google.com ([209.85.128.51]:54517)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wyuenho@HIDDEN>) id 1q5qvI-0007Zj-5C
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 12:49:44 -0400
Received: by mail-wm1-f51.google.com with SMTP id
 5b1f17b1804b1-3f7368126a6so5802555e9.0
 for <63891 <at> debbugs.gnu.org>; Sun, 04 Jun 2023 09:49:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20221208; t=1685897378; x=1688489378;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:from:to:cc:subject:date:message-id:reply-to;
 bh=+se8J70dTmNYQLVNOQmb63mss+RbHhe6EDfwxWgZXE0=;
 b=SUj0MzFoDmJT4QjvQgZpIlXEvUZkfraAHrOeBVAPhll1z++I+GrUI53ufb1T2Qh4rI
 3u1Fo9dgKpno0P/tXZ4xs57naktSR3teuPScRa+O8MRnHHpEYPClbFpEU1qDOIqonCH6
 saE6Uib+gVo3T6oGkwVr25Cj1Q1xGoCrYp465YQELP9YTxqnpqkXiwef90Cz+6MuGB73
 E9VN54D7JvGVFA/Tj6N5PZgLFE2C4NBgO30r7aJL4dgtXbomzfN4BVLeBF0VRCfZ3EtB
 NIDRD+mkwgnYOXwhlzf0+ucQd4CMFsPayrE4shj0CftGVaggkyib6VPnr89jP8jI51Yj
 CkfQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20221208; t=1685897378; x=1688489378;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=+se8J70dTmNYQLVNOQmb63mss+RbHhe6EDfwxWgZXE0=;
 b=KKKV3B1/xWw2zJ5VrxBc16GYx9zKGIXNVuFn37sEUWwycF6tAsVNr6GJDJekIxhwJx
 zaslJJG0lRNxdIzQOcAsXgb3yU11RE72LwGq5fjiwDpfuSri8Wqzisyot5Zn3ZoqVqWI
 okq2cgOnbDESSMJCRM4gQWaj/yJ1qcGZeQx6dXZjF6Sy0PxWptySRu3r5ZSGZ8srlZeH
 MFPBN789HP64Hy8hB5vjjhlRUaaCQO93y4LogEwelCmlRK8wRzKBWAXa6a3tmK+/m021
 n4wurfULapXjRIOPVqVShzxYpyuWwboUv0ziGUiCEo6CkXDNslkrgQ8R56V20FEGmo0f
 ZY9A==
X-Gm-Message-State: AC+VfDzXcG4Oge2nzEs9VdrILRX8drtvJDXhO3xUP9SUhyLHqAdC2l3o
 reOKAETTnlrbvhD+uWIG8R1A+wJ6XVY=
X-Google-Smtp-Source: ACHHUZ4GueiuzWTM8tgPLD5EtK/oaK6FzleAi5U4puI+X1F49M0kwSCCFoq039j9f4uZHnpn4VmQWg==
X-Received: by 2002:a05:600c:2906:b0:3f6:91c:4e86 with SMTP id
 i6-20020a05600c290600b003f6091c4e86mr5300370wmd.3.1685897378098; 
 Sun, 04 Jun 2023 09:49:38 -0700 (PDT)
Received: from [2a01:4b00:89a0:2400::ffff:ffff]
 ([2a01:4b00:89a0:2400:6063:8212:189a:b65])
 by smtp.gmail.com with ESMTPSA id
 s19-20020a7bc393000000b003f4248dcfcbsm11950681wmj.30.2023.06.04.09.49.37
 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 04 Jun 2023 09:49:37 -0700 (PDT)
Date: Sun, 4 Jun 2023 17:49:31 +0100
From: Jimmy Wong <wyuenho@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Message-ID: <8b93a39b-8c5c-4fee-b5c8-0668d5926abc@Spark>
In-Reply-To: <83h6rn5mn0.fsf@HIDDEN>
References: <m24jnns8tt.fsf@HIDDEN>
 <83legz5qsu.fsf@HIDDEN> <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark>
 <83jzwj5pjn.fsf@HIDDEN> <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark>
 <83h6rn5mn0.fsf@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save
 all variables if a custom file exists
X-Readdle-Message-ID: 8b93a39b-8c5c-4fee-b5c8-0668d5926abc@Spark
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="647cc0a1_37a35d46_436"
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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 (-)

--647cc0a1_37a35d46_436
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Ok you are right, the problem seems to be somewhere in Tramp on require t=
hat sets the saved-value symbol property of connection-local-profile-alis=
t and connection-local-criteria-alist without them being written to file,=
 even when enable-connection-local-variables is set to nil. When custom-s=
ave-all naively scans the obarray for symbols, sees these variables havin=
g saved-value set without going through the customize machinary, it assum=
es they are saved to a file and saves them again.
On 4 Jun 2023 at 3:25 PM +0100, Eli Zaretskii <eliz=40gnu.org>, wrote:
> > Date: Sun, 4 Jun 2023 15:00:01 +0100
> > =46rom: Jimmy Wong <wyuenho=40gmail.com>
> > Cc: 63891=40debbugs.gnu.org
> >
> > This branch: https://github.com/emacs-mirror/emacs/blob/emacs-29/lisp=
/cus-edit.el=23L1109
>
> I don't know what that is. I'm using the Emacs Git repository, the
> emacs-29 branch.
>
> > No it does not saves only one variable to file, it only saves one var=
iable to file if you have only modified
> > one variable.
>
> That's not what I see. I've modified several options using the
> menu-bar's Options menu, then typed
>
> M-x customize-save-variable RET truncate-lines RET y
>
> and saw that only truncate-lines was written to the custom file.
>
> If you see something else, please show a complete recipe that
> reproduces the behavior you see.
>
> > As a matter of fact, custom-variable-save, custom-variable-mark-to-re=
set-standard,
> > custom-face-save, custom-face-mark-to-reset-standard and custom-group=
-save all have the same
> > problem. They all call custom-save-all and they all dump all modified=
 customizable variable values on
> > file without regard to whether it=E2=80=99s a single variable, face o=
r a group the user asked Emacs to save.
>
> I wasn't talking about custom-save-all -- that indeed saves all the
> options customized in this session. I was talking about
> customize-save-variable, which prompts for a single variable and its
> value, and saves only that single variable, at least in my testing.

--647cc0a1_37a35d46_436
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

<html xmlns=3D=22http://www.w3.org/1999/xhtml=22>
<head>
<title></title>
</head>
<body>
<div name=3D=22messageBodySection=22>
<div dir=3D=22auto=22>Ok you are right, the problem seems to be somewhere=
 in Tramp on require that sets the saved-value symbol property of connect=
ion-local-profile-alist and connection-local-criteria-alist without them =
being written to file, even when enable-connection-local-variables is set=
 to nil. When custom-save-all naively scans the obarray for symbols, sees=
 these variables having saved-value set without going through the customi=
ze machinary, it assumes they are saved to a file and saves them again.</=
div>
</div>
<div name=3D=22messageReplySection=22>On 4 Jun 2023 at 3:25 PM +0100, Eli=
 Zaretskii &lt;eliz=40gnu.org&gt;, wrote:<br />
<blockquote type=3D=22cite=22 style=3D=22border-left-color: grey; border-=
left-width: thin; border-left-style: solid; margin: 5px 5px;padding-left:=
 10px;=22>
<blockquote type=3D=22cite=22>Date: Sun, 4 Jun 2023 15:00:01 +0100<br />
=46rom: Jimmy Wong &lt;wyuenho=40gmail.com&gt;<br />
Cc: 63891=40debbugs.gnu.org<br />
<br />
This branch: https://github.com/emacs-mirror/emacs/blob/emacs-29/lisp/cus=
-edit.el=23L1109<br /></blockquote>
<br />
I don't know what that is. I'm using the Emacs Git repository, the<br />
emacs-29 branch.<br />
<br />
<blockquote type=3D=22cite=22>No it does not saves only one variable to f=
ile, it only saves one variable to file if you have only modified<br />
one variable.<br /></blockquote>
<br />
That's not what I see. I've modified several options using the<br />
menu-bar's Options menu, then typed<br />
<br />
M-x customize-save-variable RET truncate-lines RET y<br />
<br />
and saw that only truncate-lines was written to the custom file.<br />
<br />
If you see something else, please show a complete recipe that<br />
reproduces the behavior you see.<br />
<br />
<blockquote type=3D=22cite=22>As a matter of fact, custom-variable-save, =
custom-variable-mark-to-reset-standard,<br />
custom-face-save, custom-face-mark-to-reset-standard and custom-group-sav=
e all have the same<br />
problem. They all call custom-save-all and they all dump all modified cus=
tomizable variable values on<br />
file without regard to whether it=E2=80=99s a single variable, face or a =
group the user asked Emacs to save.<br /></blockquote>
<br />
I wasn't talking about custom-save-all -- that indeed saves all the<br />=

options customized in this session. I was talking about<br />
customize-save-variable, which prompts for a single variable and its<br /=
>
value, and saves only that single variable, at least in my testing.<br />=
</blockquote>
</div>
</body>
</html>

--647cc0a1_37a35d46_436--





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 14:26:04 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 10:26:04 2023
Received: from localhost ([127.0.0.1]:46842 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5ogC-0003KU-Ti
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 10:26:04 -0400
Received: from eggs.gnu.org ([209.51.188.92]:54824)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1q5ogA-0003KI-Vo
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 10:25:59 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5og5-0002mF-AX; Sun, 04 Jun 2023 10:25:53 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=EQnSDKkYpXtMjh6l6O1BU3lnVGEQ684ShOsGj2MwB48=; b=ex1hekIS9jTn8Bz3C25p
 dQ1RozVdCg+PheHPTqoyv8GaQaVxUTUU/hYEslUZIRS0T2B8DnNDMOXBpgPUKdPB68609bYMMsiqr
 zCOhlxHmjm2dcTPYd0Mebk24WovmAfI286/PgXAXP8vPPEijWoxBUgBY9v1IIorkkmDFPoChsoAyI
 zp8cCL+EYkUwSs5Ynf7aitQU3tCwtiHlVJ+9RiCcqXTfrcrEV7C8ZGdXml7pq3PcSRwT8WUqKKduW
 VJsyafnFmQEhwOQqD6IvzhFuDe0T/pbsmFkrYJFkAb6NesO+zjJD/vDU+72RGfOvPdFfWcRn2xjJJ
 0vGlLfV0huRbsQ==;
Received: from [87.69.77.57] (helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5og1-00027j-Qg; Sun, 04 Jun 2023 10:25:51 -0400
Date: Sun, 04 Jun 2023 17:26:43 +0300
Message-Id: <83h6rn5mn0.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Jimmy Wong <wyuenho@HIDDEN>
In-Reply-To: <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark> (message from Jimmy
 Wong on Sun, 4 Jun 2023 15:00:01 +0100)
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save
 all variables if a custom file exists
References: <m24jnns8tt.fsf@HIDDEN>
 <83legz5qsu.fsf@HIDDEN> <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark>
 <83jzwj5pjn.fsf@HIDDEN> <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark>
MIME-version: 1.0
Content-type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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: -3.3 (---)

> Date: Sun, 4 Jun 2023 15:00:01 +0100
> From: Jimmy Wong <wyuenho@HIDDEN>
> Cc: 63891 <at> debbugs.gnu.org
> 
> This branch: https://github.com/emacs-mirror/emacs/blob/emacs-29/lisp/cus-edit.el#L1109

I don't know what that is.  I'm using the Emacs Git repository, the
emacs-29 branch.

> No it does not saves only one variable to file, it only saves one variable to file if you have only modified
> one variable.

That's not what I see.  I've modified several options using the
menu-bar's Options menu, then typed

  M-x customize-save-variable RET truncate-lines RET y

and saw that only truncate-lines was written to the custom file.

If you see something else, please show a complete recipe that
reproduces the behavior you see.

> As a matter of fact, custom-variable-save, custom-variable-mark-to-reset-standard,
> custom-face-save, custom-face-mark-to-reset-standard and custom-group-save all have the same
> problem. They all call custom-save-all and they all dump all modified customizable variable values on
> file without regard to whether it’s a single variable, face or a group the user asked Emacs to save.

I wasn't talking about custom-save-all -- that indeed saves all the
options customized in this session.  I was talking about
customize-save-variable, which prompts for a single variable and its
value, and saves only that single variable, at least in my testing.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 14:00:16 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 10:00:16 2023
Received: from localhost ([127.0.0.1]:46818 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5oHI-0002ez-1W
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 10:00:16 -0400
Received: from mail-wm1-f41.google.com ([209.85.128.41]:56523)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wyuenho@HIDDEN>) id 1q5oHG-0002eU-2H
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 10:00:14 -0400
Received: by mail-wm1-f41.google.com with SMTP id
 5b1f17b1804b1-3f623adec61so39518295e9.0
 for <63891 <at> debbugs.gnu.org>; Sun, 04 Jun 2023 07:00:14 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20221208; t=1685887208; x=1688479208;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:from:to:cc:subject:date:message-id:reply-to;
 bh=H8rvqP49mw1aMtzEVtZZCUujvd++ImGKhUhlYUxmESE=;
 b=EsRCmSuypOgYFC5eOlm5ADJfbeiOXqxF7wy8XabmX6R9MICCQN9sNm4QqoPbEK9t3z
 MIUTTfEBfzOqlbXuvaiCRWq1M02Xdck32EhrXjSWtAXCvB0gM8s6XXm0bnkaINvipDNJ
 mMn+9yqZDtU4j+UhyQ24z5F13+Wb/hPw68ZKRB4/vbt8QikB9z88icJBNDVSqa08rjgx
 XnkHLl9TcpM4UiQlO0X1Ny4hMQhHjqo3oW/K0+/Juxa0uIavdoHAeVP7dvlaO4gBTSIx
 QAj6D5jz31szogUnCp8rGI3OygDcxSU1BkKZ9E/nRiXtvTGTIst6TApMY7Pli9PHMwY7
 CbfA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20221208; t=1685887208; x=1688479208;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=H8rvqP49mw1aMtzEVtZZCUujvd++ImGKhUhlYUxmESE=;
 b=ExRATk9MrsiNrSsnZPHARablHZDgGqaN30s7Bfqh+2bXauqmSJGX3hweMDMvvz1qfJ
 P/6U3dQz7Oc5ZNYEbks4CIqMFzBX3raJ0iYtberbqXsUCrsUFxG3Oa+H5h35qkwl884G
 WwZOBpLXiD6Up9Jny6zWja8YzPwi9Wp+twcbgWcR4pf5a9qGMQkqyaeXkitr9cTmanP2
 W+BvDYExJ1VFf1ywadoEYMCxo9iceafnhVl5aL6g1RjJlw50inSAiGWM4NX5+EZKAaXb
 VDzucdXcouUItkjFdzbs/2VtuymgAxBkPm78EFWbhyBmkDWlYSX6fwmw+2D0C02kClFb
 +PeQ==
X-Gm-Message-State: AC+VfDzdK6qUGU6348gSRiOb2wxCbfKdKVdRKgwGMUDVjBL3nvfa+pm5
 kW31ORp/y5iUPgXRi60Vl0woJBxtbGw=
X-Google-Smtp-Source: ACHHUZ5agv2AHCcN0wOMGAYn4vz2ccB8Et9Z1YHBTPeF3ZssBIG0r8XTuApRgB9KG8Rl/K3LyBrumQ==
X-Received: by 2002:a1c:f719:0:b0:3f6:766:f76f with SMTP id
 v25-20020a1cf719000000b003f60766f76fmr5993222wmh.36.1685887208073; 
 Sun, 04 Jun 2023 07:00:08 -0700 (PDT)
Received: from [2a01:4b00:89a0:2400::ffff:ffff]
 ([2a01:4b00:89a0:2400:6063:8212:189a:b65])
 by smtp.gmail.com with ESMTPSA id
 f4-20020a7bc8c4000000b003f4e47c6504sm11473193wml.21.2023.06.04.07.00.07
 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 04 Jun 2023 07:00:07 -0700 (PDT)
Date: Sun, 4 Jun 2023 15:00:01 +0100
From: Jimmy Wong <wyuenho@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Message-ID: <b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark>
In-Reply-To: <83jzwj5pjn.fsf@HIDDEN>
References: <m24jnns8tt.fsf@HIDDEN>
 <83legz5qsu.fsf@HIDDEN> <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark>
 <83jzwj5pjn.fsf@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save
 all variables if a custom file exists
X-Readdle-Message-ID: b29dfb16-e8c1-4a8b-9fce-6f8dc8aeec54@Spark
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="647c98e6_5263979_436"
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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 (-)

--647c98e6_5263979_436
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

This branch: https://github.com/emacs-mirror/emacs/blob/emacs-29/lisp/cus=
-edit.el=23L1109

No it does not saves only one variable to file, it only saves one variabl=
e to file if you have only modified one variable.

As a matter of fact, custom-variable-save, custom-variable-mark-to-reset-=
standard, custom-face-save, custom-face-mark-to-reset-standard and custom=
-group-save all have the same problem. They all call custom-save-all and =
they all dump all modified customizable variable values on file without r=
egard to whether it=E2=80=99s a single variable, face or a group the user=
 asked Emacs to save.
On 4 Jun 2023 at 2:23 PM +0100, Eli Zaretskii <eliz=40gnu.org>, wrote:
> > Date: Sun, 4 Jun 2023 14:02:55 +0100
> > =46rom: Jimmy Wong <wyuenho=40gmail.com>
> > Cc: 63891=40debbugs.gnu.org
> >
> > Yes sorry, I mean customize-save-variable, custom-save-variable doesn=
=E2=80=99t exist. There=E2=80=99s a branch in
> > customize-save-variable that saves all previously updated variables t=
o the custom file if it exists.
>
> I don't think I understand. customize-save-variable saves only a
> single variable: the one whose name you type, with the value you type.
> Which branch there does more, and how can you invoke that branch=3F
>
> > I just took a look at cus-edit.el, there appears to be no function th=
at can surgically serialize just one
> > variable value to the custom file.
>
> customize-save-variable is that function.

--647c98e6_5263979_436
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

<html xmlns=3D=22http://www.w3.org/1999/xhtml=22>
<head>
<title></title>
</head>
<body>
<div name=3D=22messageBodySection=22>
<div dir=3D=22auto=22>This branch: https://github.com/emacs-mirror/emacs/=
blob/emacs-29/lisp/cus-edit.el=23L1109<br />
<br />
No it does not saves only one variable to file, it only saves one variabl=
e to file if you have only modified one variable.<br />
<br />
As a matter of fact, custom-variable-save, custom-variable-mark-to-reset-=
standard, custom-face-save, custom-face-mark-to-reset-standard and custom=
-group-save all have the same problem. They all call custom-save-all and =
they all dump all modified customizable variable values on file without r=
egard to whether it=E2=80=99s a single variable, face or a group the user=
 asked Emacs to save.</div>
</div>
<div name=3D=22messageReplySection=22>On 4 Jun 2023 at 2:23 PM +0100, Eli=
 Zaretskii &lt;eliz=40gnu.org&gt;, wrote:<br />
<blockquote type=3D=22cite=22 style=3D=22border-left-color: grey; border-=
left-width: thin; border-left-style: solid; margin: 5px 5px;padding-left:=
 10px;=22>
<blockquote type=3D=22cite=22>Date: Sun, 4 Jun 2023 14:02:55 +0100<br />
=46rom: Jimmy Wong &lt;wyuenho=40gmail.com&gt;<br />
Cc: 63891=40debbugs.gnu.org<br />
<br />
Yes sorry, I mean customize-save-variable, custom-save-variable doesn=E2=80=
=99t exist. There=E2=80=99s a branch in<br />
customize-save-variable that saves all previously updated variables to th=
e custom file if it exists.<br /></blockquote>
<br />
I don't think I understand. customize-save-variable saves only a<br />
single variable: the one whose name you type, with the value you type.<br=
 />
Which branch there does more, and how can you invoke that branch=3F<br />=

<br />
<blockquote type=3D=22cite=22>I just took a look at cus-edit.el, there ap=
pears to be no function that can surgically serialize just one<br />
variable value to the custom file.<br /></blockquote>
<br />
customize-save-variable is that function.<br /></blockquote>
</div>
</body>
</html>

--647c98e6_5263979_436--





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 13:23:11 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 09:23:11 2023
Received: from localhost ([127.0.0.1]:45351 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5nhP-0001HR-4X
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 09:23:11 -0400
Received: from eggs.gnu.org ([209.51.188.92]:54206)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1q5nhM-0001H5-8W
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 09:23:09 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5nhG-0004zK-UG; Sun, 04 Jun 2023 09:23:02 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=aDi5nJ8aX70qZZdCGU7ZgEr1soJsSMD1NlX3fhMV+Qs=; b=lpYctD8OFvywRNHEA2m8
 2LFVuSs83jniXwIYQFsr/41rti4UFGP1sw1XCKEMlWs4l6g/7rQnnpiDwIAgHRUIPkc4aQ/e2f726
 EeN3g3ik6opv9Rk63tG+EjmVM6r2Jeihh4G0u1koO+a8Gmfre+RpaAXpzB+8YjT3xviUIOj6irjKj
 kMoAVhjLkz62JyfT0lUPggYKvZwPoem3KGbCfioRY1k1aTrgNrAyRwTf3KLb8TbVYrahxGuxRNja0
 fR7UXkmL7qOETzZ31e9UZOaBQq5xkg2T1S9FI8/uFY/Bo8kAf0sYj851VA2TsQPuwdJkjiEANbutL
 D9RV11GmI+Ai6g==;
Received: from [87.69.77.57] (helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5nhG-00010T-EK; Sun, 04 Jun 2023 09:23:02 -0400
Date: Sun, 04 Jun 2023 16:23:56 +0300
Message-Id: <83jzwj5pjn.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Jimmy Wong <wyuenho@HIDDEN>
In-Reply-To: <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark> (message from Jimmy
 Wong on Sun, 4 Jun 2023 14:02:55 +0100)
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save
 all variables if a custom file exists
References: <m24jnns8tt.fsf@HIDDEN>
 <83legz5qsu.fsf@HIDDEN> <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark>
MIME-version: 1.0
Content-type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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: -3.3 (---)

> Date: Sun, 4 Jun 2023 14:02:55 +0100
> From: Jimmy Wong <wyuenho@HIDDEN>
> Cc: 63891 <at> debbugs.gnu.org
> 
> Yes sorry, I mean customize-save-variable, custom-save-variable doesn’t exist. There’s a branch in
> customize-save-variable that saves all previously updated variables to the custom file if it exists.

I don't think I understand.  customize-save-variable saves only a
single variable: the one whose name you type, with the value you type.
Which branch there does more, and how can you invoke that branch?

> I just took a look at cus-edit.el, there appears to be no function that can surgically serialize just one
> variable value to the custom file.

customize-save-variable is that function.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 13:03:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 09:03:09 2023
Received: from localhost ([127.0.0.1]:45317 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5nO0-0000e8-QX
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 09:03:09 -0400
Received: from mail-wm1-f48.google.com ([209.85.128.48]:47227)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wyuenho@HIDDEN>) id 1q5nNz-0000dn-GC
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 09:03:08 -0400
Received: by mail-wm1-f48.google.com with SMTP id
 5b1f17b1804b1-3f732d37d7cso10962055e9.2
 for <63891 <at> debbugs.gnu.org>; Sun, 04 Jun 2023 06:03:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20221208; t=1685883782; x=1688475782;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:from:to:cc:subject:date:message-id:reply-to;
 bh=mqHh0+Cyw7WFDgqGMdftokoOt6xFTq6TAeWGMQj6WB4=;
 b=SbMfAgXk6OkIU0KDNnx3qJxTndlNDevIkHVme3sNVLDsiJLYCiklrd0FxD1UCmRji+
 KcVjgEhYt1xk004VHHviiORCNCsnzislixv0lp2tmruFS33vqDDv0qG0ebTuOqvSTOgQ
 7CwCVGWsJdhISCTIkXpSRos+XBjKT86qbhcP2zJ+KpRk1arqk55Ejwir8hu0QhSF13RP
 seJw64ZGy61Aw9dqN7gQOb0pNvk9v4abndLHU8KuE8Bfj5L9y/OnlB/9jmgAQugtw5CQ
 mOZT5MKGyGnfNCxnPKatchH0WWNtRRXf3e5TsFtRLTFE/U+VgKICVm+R287AQYIGrDlP
 oELA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20221208; t=1685883782; x=1688475782;
 h=mime-version:subject:references:in-reply-to:message-id:cc:to:from
 :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
 bh=mqHh0+Cyw7WFDgqGMdftokoOt6xFTq6TAeWGMQj6WB4=;
 b=KCttCcpm4P/2krKq029bw4xOa+uNWO8pdBbkIowfbBg165PchPev9rtf3Vx8fne1eM
 8SGKVGfW62czX1t09RfcKt5NjG0LYf9ZZ2WfhC1zFIJZsEqFmoTVbIJxNuMrcE8h1oke
 8/0+Tu2s0INMkIMIxoxx1lLbmXaGFF6xPVPZXid5ZpEqBoTqVLCn/lZcMxAX93tFffRf
 rbwfVnl15oj1e2NL8Os1aGmfLxTP1uTM7K+FqxS0tfiW8ciC+5vtVMSMKe4jO2tjPe10
 TIVlz1M5eOzsjijsiywHeMH/IVHLMP2LWjgZBysqeJbD99V32tVT+cy3Uq1SLYoWSu0f
 0z7Q==
X-Gm-Message-State: AC+VfDyz6wCuP+KfttQxKLsbsF9VjwPG9GSvM2qQcK4ctm+4+MVGMXUn
 k4JBLv8kMeLOuxONAGRZDvjx+TnNzw8=
X-Google-Smtp-Source: ACHHUZ5wDksXv1IYYEr5K5WKddWvYwsiVSgHHy11Qup119IQj0jULCv0MX7G8f/tpreTZjpQG41FVw==
X-Received: by 2002:a1c:7713:0:b0:3f6:40d:136a with SMTP id
 t19-20020a1c7713000000b003f6040d136amr6514219wmi.41.1685883781454; 
 Sun, 04 Jun 2023 06:03:01 -0700 (PDT)
Received: from [2a01:4b00:89a0:2400::ffff:ffff]
 ([2a01:4b00:89a0:2400:6063:8212:189a:b65])
 by smtp.gmail.com with ESMTPSA id
 f3-20020a1c6a03000000b003f7361ca753sm2832865wmc.24.2023.06.04.06.03.00
 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 04 Jun 2023 06:03:00 -0700 (PDT)
Date: Sun, 4 Jun 2023 14:02:55 +0100
From: Jimmy Wong <wyuenho@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Message-ID: <28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark>
In-Reply-To: <83legz5qsu.fsf@HIDDEN>
References: <m24jnns8tt.fsf@HIDDEN>
 <83legz5qsu.fsf@HIDDEN>
Subject: Re: bug#63891: 29.0.91; customize-save-variable should not save
 all variables if a custom file exists
X-Readdle-Message-ID: 28e951a5-7065-4c55-b6d0-88238e8cc5eb@Spark
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="647c8b84_2cbcc4c3_436"
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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 (-)

--647c8b84_2cbcc4c3_436
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Yes sorry, I mean customize-save-variable, custom-save-variable doesn=E2=80=
=99t exist. There=E2=80=99s a branch in customize-save-variable that save=
s all previously updated variables to the custom file if it exists.

I just took a look at cus-edit.el, there appears to be no function that c=
an surgically serialize just one variable value to the custom file. =46ix=
ing this the right way will probably involve changing all the places that=
 call custom-save-all and still arguably result in a breaking change.
On 4 Jun 2023 at 1:55 PM +0100, Eli Zaretskii <eliz=40gnu.org>, wrote:
> > =46rom: Jimmy Yuen Ho Wong <wyuenho=40gmail.com>
> > Date: Sun, 04 Jun 2023 13:36:30 +0100
> >
> >
> > As a discussion from bug =2363300, it appears this long standing
> > undocumented behavior of =60custom-save-variable=60 is coming into co=
nflict
> > with the introduction of =60connection-local-*=60 variables being use=
r
> > customizable and the fact that Tramp in Emacs 29 sets them on
> > load. Here's a scenario where the combination of these behaviors resu=
lts
> > in one too many surprises:
> >
> > 0. (setf custom-file =22=7E/.emacs.d/custom.el=22)
> > 1. M-x load-library tramp (or install a package that transitively
> > requires tramp, without the user knowning)
> > 2. Now =60connection-local-profile-alist=60 and
> > =60connection-local-criteria-alist=60 are set by
> > =60hack-connection-local-variables-apply=60.
> > 3. M-x list-packages
> > 4. Installs a new package
> > 5. Now in addition to =60package-selected-packages=60 being updated, =
2
> > gigantic variables are also saved. Since these connection-local
> > variables are highly machine, application and connection dependent,
> > saving them into the custom file will make it very annoying to be sha=
red
> > across multiple machines. This violates the principle of least
> > astonishment.
>
> I think the connection-local variables should be simple variables,
> initialized from corresponding user options. Then Tramp could hack
> the variables without fear of clobbering user customizations.
>
> Michael, can this be done on emacs-29 safely enough=3F
>
> > Expectation:
> >
> > =60custom-save-variable=60 should only save the value of one variable=

> > regardless of whether a custom file exists.
>
> How is custom-save-variable involved in the above scenario=3F
>
> And what is custom-save-variable=3F did you mean customize-save-variabl=
e
> instead=3F That one does save just one variable, the one you type at
> the prompt.

--647c8b84_2cbcc4c3_436
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

<html xmlns=3D=22http://www.w3.org/1999/xhtml=22>
<head>
<title></title>
</head>
<body>
<div name=3D=22messageBodySection=22>
<div dir=3D=22auto=22>Yes sorry, I mean customize-save-variable, custom-s=
ave-variable doesn=E2=80=99t exist. There=E2=80=99s a branch in customize=
-save-variable that saves all previously updated variables to the custom =
file if it exists.<br />
<br />
I just took a look at cus-edit.el, there appears to be no function that c=
an surgically serialize just one variable value to the custom file. =46ix=
ing this the right way will probably involve changing all the places that=
 call custom-save-all and still arguably result in a breaking change.</di=
v>
</div>
<div name=3D=22messageReplySection=22>On 4 Jun 2023 at 1:55 PM +0100, Eli=
 Zaretskii &lt;eliz=40gnu.org&gt;, wrote:<br />
<blockquote type=3D=22cite=22 style=3D=22border-left-color: grey; border-=
left-width: thin; border-left-style: solid; margin: 5px 5px;padding-left:=
 10px;=22>
<blockquote type=3D=22cite=22>=46rom: Jimmy Yuen Ho Wong &lt;wyuenho=40gm=
ail.com&gt;<br />
Date: Sun, 04 Jun 2023 13:36:30 +0100<br />
<br />
<br />
As a discussion from bug =2363300, it appears this long standing<br />
undocumented behavior of =60custom-save-variable=60 is coming into confli=
ct<br />
with the introduction of =60connection-local-*=60 variables being user<br=
 />
customizable and the fact that Tramp in Emacs 29 sets them on<br />
load. Here's a scenario where the combination of these behaviors results<=
br />
in one too many surprises:<br />
<br />
0. (setf custom-file =22=7E/.emacs.d/custom.el=22)<br />
1. M-x load-library tramp (or install a package that transitively<br />
requires tramp, without the user knowning)<br />
2. Now =60connection-local-profile-alist=60 and<br />
=60connection-local-criteria-alist=60 are set by<br />
=60hack-connection-local-variables-apply=60.<br />
3. M-x list-packages<br />
4. Installs a new package<br />
5. Now in addition to =60package-selected-packages=60 being updated, 2<br=
 />
gigantic variables are also saved. Since these connection-local<br />
variables are highly machine, application and connection dependent,<br />=

saving them into the custom file will make it very annoying to be shared<=
br />
across multiple machines. This violates the principle of least<br />
astonishment.<br /></blockquote>
<br />
I think the connection-local variables should be simple variables,<br />
initialized from corresponding user options. Then Tramp could hack<br />
the variables without fear of clobbering user customizations.<br />
<br />
Michael, can this be done on emacs-29 safely enough=3F<br />
<br />
<blockquote type=3D=22cite=22>Expectation:<br />
<br />
=60custom-save-variable=60 should only save the value of one variable<br =
/>
regardless of whether a custom file exists.<br /></blockquote>
<br />
How is custom-save-variable involved in the above scenario=3F<br />
<br />
And what is custom-save-variable=3F did you mean customize-save-variable<=
br />
instead=3F That one does save just one variable, the one you type at<br /=
>
the prompt.<br /></blockquote>
</div>
</body>
</html>

--647c8b84_2cbcc4c3_436--





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at 63891 <at> debbugs.gnu.org:


Received: (at 63891) by debbugs.gnu.org; 4 Jun 2023 12:56:04 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 08:56:04 2023
Received: from localhost ([127.0.0.1]:45313 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5nH9-0000M1-Sq
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 08:56:04 -0400
Received: from eggs.gnu.org ([209.51.188.92]:55636)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1q5nH8-0000Lf-Iz
 for 63891 <at> debbugs.gnu.org; Sun, 04 Jun 2023 08:56:03 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5nH3-0006ch-99; Sun, 04 Jun 2023 08:55:57 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=c89BkPrSw7VOIjH9H6k+/m6OggmBoYoVkwDrUNfjqxk=; b=acWPScl8XZGv
 lmMN2lbc28GIT4ub8+8bXN65Gtzw5s4OGtrvHCo73W62AN8BnR8QPvXOxSW1b8YGkHqVDGA1N78li
 0y05JT5Lg6EPungRmKmSyJjWYM7OzMdiZ69Yv9/ACflxkIWfUloiUX+KJaOJkofL5/iWGpH88t+jm
 i9jHG0UoNWBN/LslMSsNr9VoJ5kmirdvk5ZNjAqe49DqEAwkcJ5NnPvgUr10+ziTQ/1+QY16N1YBD
 mMexPCiJQ2Xu0MnmjUKAf2//CklZ70JBMhXzjt1WFv62bD/jfb0I5KURS52UW+VKrYMYK4gToA9aV
 /Rvw/xHHMhYv4yNFEs4JdA==;
Received: from [87.69.77.57] (helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1q5nH2-00011r-Pa; Sun, 04 Jun 2023 08:55:57 -0400
Date: Sun, 04 Jun 2023 15:56:49 +0300
Message-Id: <83legz5qsu.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Jimmy Yuen Ho Wong <wyuenho@HIDDEN>
In-Reply-To: <m24jnns8tt.fsf@HIDDEN> (message from Jimmy Yuen
 Ho Wong on Sun, 04 Jun 2023 13:36:30 +0100)
Subject: Re: bug#63891: 29.0.91;
 customize-save-variable should not save all variables if a custom
 file exists
References: <m24jnns8tt.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 63891
Cc: 63891 <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: -3.3 (---)

> From: Jimmy Yuen Ho Wong <wyuenho@HIDDEN>
> Date: Sun, 04 Jun 2023 13:36:30 +0100
> 
> 
> As a discussion from bug #63300, it appears this long standing
> undocumented behavior of `custom-save-variable` is coming into conflict
> with the introduction of `connection-local-*` variables being user
> customizable and the fact that Tramp in Emacs 29 sets them on
> load. Here's a scenario where the combination of these behaviors results
> in one too many surprises:
> 
> 0. (setf custom-file "~/.emacs.d/custom.el")
> 1. M-x load-library tramp (or install a package that transitively
> requires tramp, without the user knowning)
> 2. Now `connection-local-profile-alist` and
> `connection-local-criteria-alist` are set by
> `hack-connection-local-variables-apply`.
> 3. M-x list-packages
> 4. Installs a new package
> 5. Now in addition to `package-selected-packages` being updated, 2
> gigantic variables are also saved. Since these connection-local
> variables are highly machine, application and connection dependent,
> saving them into the custom file will make it very annoying to be shared
> across multiple machines. This violates the principle of least
> astonishment.

I think the connection-local variables should be simple variables,
initialized from corresponding user options.  Then Tramp could hack
the variables without fear of clobbering user customizations.

Michael, can this be done on emacs-29 safely enough?

> Expectation:
> 
> `custom-save-variable` should only save the value of one variable
> regardless of whether a custom file exists.

How is custom-save-variable involved in the above scenario?

And what is custom-save-variable? did you mean customize-save-variable
instead?  That one does save just one variable, the one you type at
the prompt.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 4 Jun 2023 12:36:38 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jun 04 08:36:38 2023
Received: from localhost ([127.0.0.1]:45302 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1q5myM-0008At-Cw
	for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 08:36:38 -0400
Received: from lists.gnu.org ([209.51.188.17]:51864)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <wyuenho@HIDDEN>) id 1q5myL-0008Al-0O
 for submit <at> debbugs.gnu.org; Sun, 04 Jun 2023 08:36:37 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <wyuenho@HIDDEN>) id 1q5myK-00068k-Lu
 for bug-gnu-emacs@HIDDEN; Sun, 04 Jun 2023 08:36:36 -0400
Received: from mail-wr1-x42f.google.com ([2a00:1450:4864:20::42f])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <wyuenho@HIDDEN>) id 1q5myJ-0002XR-4H
 for bug-gnu-emacs@HIDDEN; Sun, 04 Jun 2023 08:36:36 -0400
Received: by mail-wr1-x42f.google.com with SMTP id
 ffacd0b85a97d-30ad99fa586so3809068f8f.2
 for <bug-gnu-emacs@HIDDEN>; Sun, 04 Jun 2023 05:36:33 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20221208; t=1685882192; x=1688474192;
 h=mime-version:message-id:date:subject:to:from:from:to:cc:subject
 :date:message-id:reply-to;
 bh=XsmQBwXtCCL9cFp/MnemsFJkwQf+vkaQjRdKHi4/aUs=;
 b=M41GM02KakoBS1/s/rW+A/CwlAXTUE6OC7aNh0JKe+CtAkD7zJQ41mJIxB5pqlJLgh
 20BAXzRbxch68e0qb6dTEsJsIwM9b2ZCg5DOTiWYL//u7H1vCfhqRprMGyCuVsb3XX1r
 kwM9v/dS6rqRRttSXe55Nr86U4OfDVEoz01VBSr6lBiBgSVFWpkxFoN9vqr4rJYmHH0L
 Ks5dnK92fnSyxGUK3zqL/nYoShtIA5EXvfNcWyNNgg/CJQdKhNvrmdLS6m4LjiUWmZa9
 vuT6lWNqYiu0sWhK3M2q1zOpekdLvDHxl/wmGdFkXw+xSFqUglRIdhhYlUXVNOGg82ra
 TLEg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20221208; t=1685882192; x=1688474192;
 h=mime-version:message-id:date:subject:to:from:x-gm-message-state
 :from:to:cc:subject:date:message-id:reply-to;
 bh=XsmQBwXtCCL9cFp/MnemsFJkwQf+vkaQjRdKHi4/aUs=;
 b=giQ7brqgku41XgHgjnrDCp/0Ewsiypt3eIqjvsXUR501yKDcRM7N5s2Jb3TA7k+op7
 uA2pPCW4Jzgzu5wNnu/B7Ww6tTSo9+KUHNtkKdGrIvXUYLj/QJ65GBdTZL9AA1lVAEzn
 9OGRMUg47L/rrOGBF7Ike1DorjqRi5kEwmFHTgW9dCSZOtqweia3SQIDz37hvgJs0pEj
 0PswrWsjFD+rG+q9dtZCTT3FvNxNoBLbVr3AOUdBSqVYAjF4pUdPLiPXiNK2HvfNsYLB
 w1euannzq0sC3aQN/Q3y2mQttpgsZ3eF0GFUOzio2VnVniF0Ov6nvKUzOcWKyyxM5f/z
 kuBg==
X-Gm-Message-State: AC+VfDzrwoXJjmnTltzxydHAd3E0+/lupuwo/k8F3KYtPXYliOibbFxd
 ZqKk7fuQFBYAPsL1NKrqn0kWeMLncww=
X-Google-Smtp-Source: ACHHUZ57Jv5g5fHoen9x5NxPRlKHPPlmeZU4T+R4eXcFfdAXkweKkEhTZ8mFHFQI9ADBh4nPh7uLXg==
X-Received: by 2002:adf:cd12:0:b0:309:4da8:7713 with SMTP id
 w18-20020adfcd12000000b003094da87713mr4355561wrm.64.1685882191607; 
 Sun, 04 Jun 2023 05:36:31 -0700 (PDT)
Received: from MobileCat.localdomain ([2a01:4b00:89a0:2400:6063:8212:189a:b65])
 by smtp.gmail.com with ESMTPSA id
 h15-20020a5d688f000000b002f6176cc6desm6972977wru.110.2023.06.04.05.36.30
 for <bug-gnu-emacs@HIDDEN>
 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256);
 Sun, 04 Jun 2023 05:36:31 -0700 (PDT)
From: Jimmy Yuen Ho Wong <wyuenho@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 29.0.91; customize-save-variable should not save all variables if a
 custom file exists
Date: Sun, 04 Jun 2023 13:36:30 +0100
Message-ID: <m24jnns8tt.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
Received-SPF: pass client-ip=2a00:1450:4864:20::42f;
 envelope-from=wyuenho@HIDDEN; helo=mail-wr1-x42f.google.com
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,
 T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.3 (-)
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 (--)


As a discussion from bug #63300, it appears this long standing
undocumented behavior of `custom-save-variable` is coming into conflict
with the introduction of `connection-local-*` variables being user
customizable and the fact that Tramp in Emacs 29 sets them on
load. Here's a scenario where the combination of these behaviors results
in one too many surprises:

0. (setf custom-file "~/.emacs.d/custom.el")
1. M-x load-library tramp (or install a package that transitively
requires tramp, without the user knowning)
2. Now `connection-local-profile-alist` and
`connection-local-criteria-alist` are set by
`hack-connection-local-variables-apply`.
3. M-x list-packages
4. Installs a new package
5. Now in addition to `package-selected-packages` being updated, 2
gigantic variables are also saved. Since these connection-local
variables are highly machine, application and connection dependent,
saving them into the custom file will make it very annoying to be shared
across multiple machines. This violates the principle of least
astonishment.

Expectation:

`custom-save-variable` should only save the value of one variable
regardless of whether a custom file exists.




Acknowledgement sent to Jimmy Yuen Ho Wong <wyuenho@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#63891; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Sat, 28 Oct 2023 10:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.