From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "J.P." Newsgroups: gmane.emacs.bugs Subject: bug#60784: 29.0.60; ERC 5.5: Don't interfere with non-module minor modes in erc-open Date: Tue, 17 Jan 2023 06:33:53 -0800 Message-ID: <87lem1telq.fsf__4949.05102984689$1673966125$gmane$org@neverwas.me> References: <87cz7iwmae.fsf@neverwas.me> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39868"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-erc@gnu.org To: 60784-done@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jan 17 15:35:18 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pHn3V-000A7V-Cr for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 17 Jan 2023 15:35:17 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pHn3Q-00030v-2H; Tue, 17 Jan 2023 09:35:12 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pHn3H-0002z8-DW for bug-gnu-emacs@gnu.org; Tue, 17 Jan 2023 09:35:07 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pHn3G-00044f-K3 for bug-gnu-emacs@gnu.org; Tue, 17 Jan 2023 09:35:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pHn3G-00019c-4h for bug-gnu-emacs@gnu.org; Tue, 17 Jan 2023 09:35:02 -0500 Resent-From: "J.P." Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Tue, 17 Jan 2023 14:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 60784 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Mail-Followup-To: 60784@debbugs.gnu.org, jp@neverwas.me, jp@neverwas.me Original-Received: via spool by 60784-done@debbugs.gnu.org id=D60784.16739660484359 (code D ref 60784); Tue, 17 Jan 2023 14:35:01 +0000 Original-Received: (at 60784-done) by debbugs.gnu.org; 17 Jan 2023 14:34:08 +0000 Original-Received: from localhost ([127.0.0.1]:36192 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pHn2O-00018F-EA for submit@debbugs.gnu.org; Tue, 17 Jan 2023 09:34:08 -0500 Original-Received: from mail-108-mta162.mxroute.com ([136.175.108.162]:43503) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pHn2M-00017s-Vv for 60784-done@debbugs.gnu.org; Tue, 17 Jan 2023 09:34:07 -0500 Original-Received: from mail-111-mta2.mxroute.com ([136.175.111.2] filter006.mxroute.com) (Authenticated sender: mN4UYu2MZsgR) by mail-108-mta162.mxroute.com (ZoneMTA) with ESMTPSA id 185c026a7ee000011e.001 for <60784-done@debbugs.gnu.org> (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256); Tue, 17 Jan 2023 14:33:56 +0000 X-Zone-Loop: 00eb869fa2c0c65528649c29fd86a2e94c376a409bc8 X-Originating-IP: [136.175.111.2] DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=neverwas.me ; s=x; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To: 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=0kS+VVzmsE6X+q7UXv5Oymj+ocZ4fWahxoT2CESIhNY=; b=QRZlqS1cdEAfSq1UgfcTv8aUkn PfTWTxC/qRZW3Ul5iQvPxzz9FoEZTBuYNgpSfNtnWlzo7UB92oofBGLXeJ1XNFL/e5pqg15tM7Nby hb1rvGaOp7ZUc24q5MAr6SXnJglgnfShRfQL6VJrTGnSbEChTatpIF9qGbVqUSo5NC6gNnmMXx7qA Gob5TVPouMzd5S/GKdKtnUv0wSAwL+Z29SYQMKD9dXXQwpO8h6u8bBaRoUsWjG3oTqulJEj+cnItZ sRM8KFdVFj+0FU0ffo2uyvYPtgNKxsx1OZQzfRKofPh7XwfU/GPFxeInXz9HurZsWUTqeOH8XDkWz DfgxJAsQ==; In-Reply-To: <87cz7iwmae.fsf@neverwas.me> (J. P.'s message of "Fri, 13 Jan 2023 06:18:17 -0800") X-Authenticated-Id: masked@neverwas.me X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:253554 Archived-At: "J.P." writes: > ERC currently takes ownership of any minor mode it encounters whose name > happens to be prefixed with "erc-" as long as its mode variable is set > locally in an ERC buffer. That is, it propagates the enabled/disabled > state to new `erc-mode' buffers, possibly by calling the namesake > minor-mode function. This makes sense for modes defined by "local" > modules, whether built-in or third-party. But other, non-module minor > modes that just happen to use the same top-level library namespace > should be left alone. I've addressed this in a slightly more reliable way that doesn't depend on heuristics. Instead of banking on the unlikelihood of a non-module minor mode also defining a function suffixed with "-enable," I've opted for tagging a module's minor-mode symbol with the property `erc-module', to be paired with its canonical symbol as a value. It happens that while addressing this, I stumbled upon another, closely related (and arguably more important) bug stemming from the "local modules" change set (bug#57955), which was installed last November to support the SASL module. Basically, a local module's activation state (i.e., that of its minor-mode variable) wouldn't survive reconnections, as vociferously claimed. My oversight here owes its inception, in part, to the SASL module's lack of interest in target buffers, which its test cases came to reflect. And while the (vital) matter of reinstating a local module's associated data falls beyond the scope of this change, it ranks highly among the improvements I'd like to see in ERC's next major release. Thanks (and closing).