GNU bug report logs - #54536
29.0.50; Improve ERC's handling of multiline prompt input

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: "J.P." <jp@HIDDEN>; Keywords: patch; dated Wed, 23 Mar 2022 13:27:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

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


Received: (at 54536) by debbugs.gnu.org; 26 Mar 2022 16:44:48 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Mar 26 12:44:48 2022
Received: from localhost ([127.0.0.1]:54617 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nY9Wy-0002Ku-CL
	for submit <at> debbugs.gnu.org; Sat, 26 Mar 2022 12:44:48 -0400
Received: from quimby.gnus.org ([95.216.78.240]:54976)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nY9Ww-0002Kg-Sa
 for 54536 <at> debbugs.gnu.org; Sat, 26 Mar 2022 12:44:47 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=sT78at6y285yDWtPhOk8/P7H5fVCJz6+KMWMdLYOY28=; b=Ba49QXMqEl8p2U4j5T/4fdSDCd
 dbaRc8eQdAUZnkhWwaLN5d/M+9o7qFERttmR1F798UDLTuIKi4Mdv/irmHpwiCAPzpGj0nPhfSTAL
 MMlLAjc62nWEatQ80QjcwreTWI4ASTN+GgRZLF2p2vZ8H55BNXEWju7FynpynkQlns8w=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nY9Wo-00017q-5Y; Sat, 26 Mar 2022 17:44:40 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: "J.P." <jp@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
 <8735j7jecz.fsf@HIDDEN> <87tubm53ar.fsf@HIDDEN>
 <874k3mf3th.fsf@HIDDEN> <87ee2p3kgx.fsf@HIDDEN>
Date: Sat, 26 Mar 2022 17:44:37 +0100
In-Reply-To: <87ee2p3kgx.fsf@HIDDEN> (J. P.'s message of "Fri, 25 Mar
 2022 12:23:10 -0700")
Message-ID: <87bkxsd5oq.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  "J.P." <jp@HIDDEN> writes: > BTW, I think these can go:
 > > refs/heads/features/erc-message-tags > refs/heads/fix/bug-34657-erc-hooks
 > > Is it customary to contact the authors before deleting? If the branches
 have been merged (or their contents have been applied to the trunk otherwise), 
 it's OK to delete them. If not, it's better to contact the authors first.
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 54536
Cc: 54536 <at> debbugs.gnu.org, emacs-erc@HIDDEN,
 Michael Albinus <michael.albinus@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

"J.P." <jp@HIDDEN> writes:

> BTW, I think these can go:
>
>   refs/heads/features/erc-message-tags
>   refs/heads/fix/bug-34657-erc-hooks
>
> Is it customary to contact the authors before deleting?

If the branches have been merged (or their contents have been applied to
the trunk otherwise), it's OK to delete them.  If not, it's better to
contact the authors first.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

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


Received: (at 54536) by debbugs.gnu.org; 25 Mar 2022 19:23:26 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Mar 25 15:23:26 2022
Received: from localhost ([127.0.0.1]:52480 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXpWw-0000m6-8C
	for submit <at> debbugs.gnu.org; Fri, 25 Mar 2022 15:23:26 -0400
Received: from mail-108-mta119.mxroute.com ([136.175.108.119]:42639)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jp@HIDDEN>) id 1nXpWs-0000lc-5R
 for 54536 <at> debbugs.gnu.org; Fri, 25 Mar 2022 15:23:22 -0400
Received: from filter006.mxroute.com ([140.82.40.27]
 140.82.40.27.vultrusercontent.com)
 (Authenticated sender: mN4UYu2MZsgR)
 by mail-108-mta119.mxroute.com (ZoneMTA) with ESMTPSA id
 17fc288664e000fe85.001 for <54536 <at> debbugs.gnu.org>
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256);
 Fri, 25 Mar 2022 19:23:13 +0000
X-Zone-Loop: a7ba8173ef6bddd7b040771e7bf5a365d4e41ab0e728
X-Originating-IP: [140.82.40.27]
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:In-Reply-To:Date:References:
 Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID:
 Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
 :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=nWqfHroeCmTnpUfGBFfUG2TYM++0/WcIw8/jFdiewww=; b=VB36m1B6RrYzkU2rE6cKaoxeCJ
 nh2rDI03LGzwXB4Q/qstuG66nXx15C7wHay7S1vYnecKFzChQoBcZS1foD8uJNJ0J6Qk87q5ISktj
 tqN5pTvzDBAYx5doVNt1unIJw27tV06GrfbR7MVSv0CYEuxk43VVqYWYxYj7fbcgVzLFFWZFXzQNa
 7SKsrobx0xCnjSRz64qPd9w8poKUm1dTS5LQ/Xg/zmV/sZB07XgOhRVbyii+eHWn3yRJZbv7RhGfY
 YXUF892CL/y2NJxI2lQxPrm8/cXT1LZ6NTVVc4iDvOY/EssXA76D/8dbnxjZf7CFEvxhUzOCqibin
 oXkwm+rA==;
From: "J.P." <jp@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
 <8735j7jecz.fsf@HIDDEN> <87tubm53ar.fsf@HIDDEN>
 <874k3mf3th.fsf@HIDDEN>
Date: Fri, 25 Mar 2022 12:23:10 -0700
In-Reply-To: <874k3mf3th.fsf@HIDDEN> (Lars Ingebrigtsen's message of "Fri,
 25 Mar 2022 16:29:46 +0100")
Message-ID: <87ee2p3kgx.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-AuthUser: masked@HIDDEN
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 54536
Cc: 54536 <at> debbugs.gnu.org, emacs-erc@HIDDEN,
 Michael Albinus <michael.albinus@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> Calling the branch fix/whatever is fine.

Thanks.

BTW, I think these can go:

  refs/heads/features/erc-message-tags
  refs/heads/fix/bug-34657-erc-hooks

Is it customary to contact the authors before deleting?




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

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


Received: (at 54536) by debbugs.gnu.org; 25 Mar 2022 19:20:55 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Mar 25 15:20:55 2022
Received: from localhost ([127.0.0.1]:52462 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXpUU-0000gR-UI
	for submit <at> debbugs.gnu.org; Fri, 25 Mar 2022 15:20:55 -0400
Received: from mail-108-mta154.mxroute.com ([136.175.108.154]:40605)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jp@HIDDEN>) id 1nXpUT-0000gD-Af
 for 54536 <at> debbugs.gnu.org; Fri, 25 Mar 2022 15:20:53 -0400
Received: from filter006.mxroute.com ([140.82.40.27]
 140.82.40.27.vultrusercontent.com)
 (Authenticated sender: mN4UYu2MZsgR)
 by mail-108-mta154.mxroute.com (ZoneMTA) with ESMTPSA id
 17fc286229d000fe85.001 for <54536 <at> debbugs.gnu.org>
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256);
 Fri, 25 Mar 2022 19:20:44 +0000
X-Zone-Loop: fc846c47a576acf7d9dd21926ff85c230070018d1d2e
X-Originating-IP: [140.82.40.27]
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:In-Reply-To:Date:References:
 Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID:
 Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
 :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=1aSXPbavvrX3ZsbS1iK5H41YAS0QvhkjcV+MalkBPSs=; b=R79LOygvE30YT6qkiVatk6dOGb
 yWJQEU1idCgv7lzj5rUBZBSK2/SHvcxGC+icXmidgNPjQQwp/ptPwxchmsWQ2Wdmd72nGCuRhh0yY
 CT15tT/9I37xmCSOT1DKdSZhbEIl4LE2hKagLSLWbLRCYVo+Ukh3o7aMa0aUxxKq00HntyaJGscDz
 fFRlsDDpZeud5Idx44GB1S3geSRQKfe6+F1knrc0d4nLU8SB/oXAeG42VvwR3M8evw/5V5zEF2tp7
 wzG+aQ7QLB6Tz+yECi2ba6PGdB1i3DB1fJl0B+QL8yaQBstyVE6uhPKWvt0ZnBE0FCzlFgaoNaLBv
 mDJEPkIg==;
From: "J.P." <jp@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf@HIDDEN> <87zgledp6a.fsf@HIDDEN>
Date: Fri, 25 Mar 2022 12:20:41 -0700
In-Reply-To: <87zgledp6a.fsf@HIDDEN> (Lars Ingebrigtsen's message of "Fri,
 25 Mar 2022 16:31:25 +0100")
Message-ID: <87lewx3kl2.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-AuthUser: masked@HIDDEN
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 54536
Cc: emacs-erc@HIDDEN, 54536 <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 (-)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> "J.P." <jp@HIDDEN> writes:
>
>> I'd like to get #48598 ("buffer-naming collisions involving bouncers in
>> ERC") up to snuff relatively soon. Would it make sense to petition
>> emacs-devel for eyeballs at some point? 
>
> Sure, if you want to.  I had a brief peek myself, but the patch series
> was so long that I didn't really have anything to say.  :-/

Thanks for the peek. Your impression is more than fair. I think for now
I'll try soliciting specific questions, perhaps via top-level replies to
that bug but with subject headers changed to reflect whatever's being
posed (while also Cc-ing various persons where appropriate). And in
cases where a question may have broader relevance, I'll hit up
help-gnu-emacs first/instead.




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

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


Received: (at 54536) by debbugs.gnu.org; 25 Mar 2022 15:31:36 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Mar 25 11:31:36 2022
Received: from localhost ([127.0.0.1]:52200 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXlua-00018x-E7
	for submit <at> debbugs.gnu.org; Fri, 25 Mar 2022 11:31:36 -0400
Received: from quimby.gnus.org ([95.216.78.240]:42702)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nXluY-00018k-Fz
 for 54536 <at> debbugs.gnu.org; Fri, 25 Mar 2022 11:31:35 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=O+XCgErxTwRaXf70cmfrAwn8donqG2k4D9bLvuAlYAM=; b=kNULfIk6fg1AXxPohiqTynQZFQ
 BCptvYRijtZTzCElKiS+jam3XzNbqQGfmwAidjOLx9FvJ78Xs0zpvE/MAwbfY/Nb0hl9GI0EMeRYo
 awcYoQ3xyZUAkBunfn5FOzqzir2oUy4Kzbind7kAjmV/PzyKOMoZ19dKDBu0+UUAnQ2o=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nXluQ-0004MD-CF; Fri, 25 Mar 2022 16:31:28 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: "J.P." <jp@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf@HIDDEN>
Date: Fri, 25 Mar 2022 16:31:25 +0100
In-Reply-To: <87ee2rb04e.fsf@HIDDEN> (J. P.'s message of "Thu, 24 Mar
 2022 12:50:57 -0700")
Message-ID: <87zgledp6a.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: "J.P." <jp@HIDDEN> writes: > I'd like to get #48598
 ("buffer-naming
 collisions involving bouncers in > ERC") up to snuff relatively soon. Would
 it make sense to petition > emacs-devel for eyeballs at some point? 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 54536
Cc: emacs-erc@HIDDEN, 54536 <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 (---)

"J.P." <jp@HIDDEN> writes:

> I'd like to get #48598 ("buffer-naming collisions involving bouncers in
> ERC") up to snuff relatively soon. Would it make sense to petition
> emacs-devel for eyeballs at some point? 

Sure, if you want to.  I had a brief peek myself, but the patch series
was so long that I didn't really have anything to say.  :-/

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

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


Received: (at 54536) by debbugs.gnu.org; 25 Mar 2022 15:29:58 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Mar 25 11:29:58 2022
Received: from localhost ([127.0.0.1]:52183 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXlt0-00013g-2u
	for submit <at> debbugs.gnu.org; Fri, 25 Mar 2022 11:29:58 -0400
Received: from quimby.gnus.org ([95.216.78.240]:42674)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nXlsx-00013S-Me
 for 54536 <at> debbugs.gnu.org; Fri, 25 Mar 2022 11:29:57 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=y50Zvsf1nFFMUP8OvXr3b9gKS+CmOyOu8io2H66uay4=; b=ja9EOj0u8byMxJhR6C8fWFQaG2
 IC3ajqGw84MRWSesiSfWKSwQ9XOjPkPaeTMpnfL1Xv1dijmB8b19zpD3EiW03JvMJU+/M47fjtkrn
 JyoxFQVjFdurBMQe6GcPK6VG7y7zn+0WjZwypS8QBHuY0yruv6NcxvReq+0T0iKmw0Rc=;
Received: from [84.212.220.105] (helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nXlso-0004JB-KR; Fri, 25 Mar 2022 16:29:48 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: "J.P." <jp@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
 <8735j7jecz.fsf@HIDDEN> <87tubm53ar.fsf@HIDDEN>
Date: Fri, 25 Mar 2022 16:29:46 +0100
In-Reply-To: <87tubm53ar.fsf@HIDDEN> (J. P.'s message of "Thu, 24 Mar
 2022 16:38:52 -0700")
Message-ID: <874k3mf3th.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: "J.P." <jp@HIDDEN> writes: > Thanks a lot for the
 explanation.
 Among those prefixes, "fix" seems the > least misleading for my purposes,
 those being (1) rapid iteration toward > a passing pipeline and (2) minimal
 distraction fo [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 54536
Cc: 54536 <at> debbugs.gnu.org, emacs-erc@HIDDEN,
 Michael Albinus <michael.albinus@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

"J.P." <jp@HIDDEN> writes:

> Thanks a lot for the explanation. Among those prefixes, "fix" seems the
> least misleading for my purposes, those being (1) rapid iteration toward
> a passing pipeline and (2) minimal distraction for others. Hopefully,
> there's already precedent for more ephemeral, fly-by-night "fix/*"
> branches. If so, and there's a prescribed naming scheme to that end
> (something like "fix/bug-48598-temp" or similar), perusing the remote
> refs hasn't revealed it. Regardless, I'll wait for a go-ahead before
> trying anything.

Calling the branch fix/whatever is fine.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

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


Received: (at 54536) by debbugs.gnu.org; 24 Mar 2022 23:39:08 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Mar 24 19:39:08 2022
Received: from localhost ([127.0.0.1]:49665 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXX2p-0003Ca-Rv
	for submit <at> debbugs.gnu.org; Thu, 24 Mar 2022 19:39:08 -0400
Received: from mail-108-mta12.mxroute.com ([136.175.108.12]:38043)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jp@HIDDEN>) id 1nXX2n-0003C0-CF
 for 54536 <at> debbugs.gnu.org; Thu, 24 Mar 2022 19:39:06 -0400
Received: from filter006.mxroute.com ([140.82.40.27]
 140.82.40.27.vultrusercontent.com)
 (Authenticated sender: mN4UYu2MZsgR)
 by mail-108-mta12.mxroute.com (ZoneMTA) with ESMTPSA id 17fbe4c27ae000fe85.001
 for <54536 <at> debbugs.gnu.org>
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256);
 Thu, 24 Mar 2022 23:38:56 +0000
X-Zone-Loop: 23e841f0b2a8c0e0218d41fc1f37cdfa19efe2908955
X-Originating-IP: [140.82.40.27]
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:In-Reply-To:Date:References:
 Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID:
 Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
 :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=SFcOMhVeccS5nN0+1KeqRf5Hld0N1rLOTIIt+Jg7l7g=; b=bSpZKIFDQa1QMVixFlKjR0p8HI
 P46DYZPiw1cpzf3REJwDJ/1jDEB79Fj/NedFhi2OKiUmBbCLI9GIECpqwl0w1UxvUzyBvMcIROcXS
 KeM6muSCwM2ighonIe1uf5xK5kPb9tSi0JZUWHYJFwTAJdmzwlraqhyd+6duFClz+sxHMeEBwzKE9
 F16+LzttwtbInXV0ca7thyG43ME3/Ttda4QxUy54C9SwWbgeSXxr1LT2pN+C3k705OAtq7+tVSRc7
 LW/Zq0UmwLvE08O2yyVAE7Te3lrA0CH5qXbWHh2D/hfgqW/U1eaMciMvPFwIaed4f6mM3bYQT+sGM
 ORcKtK1Q==;
From: "J.P." <jp@HIDDEN>
To: Michael Albinus <michael.albinus@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
 <8735j7jecz.fsf@HIDDEN>
Date: Thu, 24 Mar 2022 16:38:52 -0700
In-Reply-To: <8735j7jecz.fsf@HIDDEN> (Michael Albinus's message of "Thu, 24
 Mar 2022 21:16:12 +0100")
Message-ID: <87tubm53ar.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-AuthUser: masked@HIDDEN
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 54536
Cc: Lars Ingebrigtsen <larsi@HIDDEN>, emacs-erc@HIDDEN,
 54536 <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,

Michael Albinus <michael.albinus@HIDDEN> writes:

> So your branch name must start with one of these words.

Thanks a lot for the explanation. Among those prefixes, "fix" seems the
least misleading for my purposes, those being (1) rapid iteration toward
a passing pipeline and (2) minimal distraction for others. Hopefully,
there's already precedent for more ephemeral, fly-by-night "fix/*"
branches. If so, and there's a prescribed naming scheme to that end
(something like "fix/bug-48598-temp" or similar), perusing the remote
refs hasn't revealed it. Regardless, I'll wait for a go-ahead before
trying anything.

Thanks again,
J.P.




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

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


Received: (at 54536) by debbugs.gnu.org; 24 Mar 2022 20:16:27 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Mar 24 16:16:27 2022
Received: from localhost ([127.0.0.1]:49492 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXTsh-0006Me-EC
	for submit <at> debbugs.gnu.org; Thu, 24 Mar 2022 16:16:27 -0400
Received: from mout.gmx.net ([212.227.17.21]:37021)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <michael.albinus@HIDDEN>) id 1nXTsd-0006MQ-LU
 for 54536 <at> debbugs.gnu.org; Thu, 24 Mar 2022 16:16:25 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net;
 s=badeba3b8450; t=1648152974;
 bh=Pf99kGWFZ1bR/n8DUStRROiQS5bFbS6ReTe+rN6DNtM=;
 h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To;
 b=XnvEslrBZLjhA62S/1JrC53TvT23+ushq/tHWGk0nSHIyHT8M4X6ZqnFXyzvorwoc
 lVcS8kEO/wPHUDQcqHI+hKH7hBsch4pEXyHmjbBYH3BUMS276etTme54KSko8cQLHW
 ED5hAR9kFOXa4YBx9+u4UQMbUUQqRIcTlQFvFiQ8=
X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c
Received: from gandalf.gmx.de ([79.140.118.40]) by mail.gmx.net (mrgmx105
 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MNKlu-1nixHz43xa-00Oo2d; Thu, 24
 Mar 2022 21:16:14 +0100
From: Michael Albinus <michael.albinus@HIDDEN>
To: "J.P." <jp@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
 <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
Date: Thu, 24 Mar 2022 21:16:12 +0100
In-Reply-To: <87ee2rb04e.fsf__35149.1299386666$1648151549$gmane$org@HIDDEN>
 (J. P.'s message of "Thu, 24 Mar 2022 12:50:57 -0700")
Message-ID: <8735j7jecz.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Provags-ID: V03:K1:IziMF4ARJhBQydO6tQDtEeWEe66fxE+lRUgQNen3u9bRRhUxi6t
 VcEoCERzerYAQxfw4lBZcMwjcvnQRxpBcXjYSaliYDAG9Wmj9WWlZw0lMyQlidM6L9XUrwE
 uIHsoxH0MhHKApHIkQAkAPfaVvjJoejl1epUmY6jZEaWrtnjwerRG1eJZcqY88Ksv2avscA
 LHqE7g75aG9bEvfYqJNpw==
X-Spam-Flag: NO
X-UI-Out-Filterresults: notjunk:1;V03:K0:7cNyLOBVNOI=:y8nMDjQa87wR6RtQl1RLIP
 rMsKenTJPAnkaOcnpmHfBPtFfsFC+Yi9vsDP++H/I+Qwr04inZnaXksEfkBVGC69YvSZTENY6
 roiz7RRmLymfX7GcPr3fGLUeuel5AHp/juEdsU90iBgpb7J8BNufF/5eI711eu2D7P+WiUj1h
 7bPPnE9Z3qSwdcw6PA/tGIl3ZbFrZB2XQwEWWpU/iHV9+T9Kyh2rHs/r9LbmvJTT0k5dBvIc4
 F9XhLLx6/S0pqa7KEJuXIdMySu3vlY5nTry6BEbygqTrkfTfz/QgkvtHoKVfm+9MMc6KzWtdR
 8R9zPn42en8C0HEiA0naOfd5Xuy1FjW0LrIbH8MyFcCqUi2RluM8mcQQ8/pXKgfWKLaHRyHz+
 K0m4eqMI4LFEouo7on02VpGmic1kTyQ7ZdXV32dLmeKx3opVpZq9qLPPDSHqY3Bn6Z3W5euB1
 oupdIBGIVTqVQFqASm7x01W5gzrkQA1kako6pEihSuLCI+9fzJgdai+pQB6yHK5Q1Fp1PEgb/
 knKtvmgS88JsJR9hxbmFgfR6dJxXr6HG4P4AOGR/P69HJrJGr27uNwvj25Y9wwrzD9YdsXYrf
 Ss8buquboEQSMp770JouTJZFqm6QhM8OptFbwuiyfz2gOEd/MbpRxWnJ4ybUlwspQAadW4iuo
 BhSLTeSUMvh8dmjFuDugb5Lc3CMOIMESzEnh4gZ1/a0ZxpXrzIu4rwewQ/z3X6n4CAMqyX2rF
 khmVyy1I8efRkqBtMbfNcrfb1dlMKXxXPvFsXR5wx3k7qerOn3G/+h/KcbWRacCT0Wb6Bc3U5
 DMS6e2/C88HusAoqOdZZsJwdpUPzvTG5nftKj4TcwkDw4/9LlOQvtkqxa9Kilv/dO92ObxLCU
 f6Jn+flQIpdHWCS7a5H1rdkbPdVDZqhQDDOZ8EoAxaFPrhWQYPb/qfNKoGfIYhQD4wBoDp3pT
 y2mx6e+Ai1iFZ/rJ6OMyDqmVQZr2PZ4TWPqbbD6V8aaT98FA3xttzA9jafmcj3wG+urcB45f+
 OXvmWzmHw8t93Unu8DVsLfrNrtbxGnH8B0acY8tSgTC5MbELpG2pWSs6FsBq3sAC9IHx5DyFq
 DjCwJgRZ/ozdXk=
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 54536
Cc: Lars Ingebrigtsen <larsi@HIDDEN>, emacs-erc@HIDDEN,
 54536 <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 (-)

"J.P." <jp@HIDDEN> writes:

Hi,

> I'd like to get #48598 ("buffer-naming collisions involving bouncers in
> ERC") up to snuff relatively soon. Would it make sense to petition
> emacs-devel for eyeballs at some point? Also, is there any way to try
> out some patches on EMBA CI? I have a feeling some of my tests that work
> locally and on GitLab.com's GCP runners may have to be tuned a bit for
> EMBA. (Or would these questions be better put to the build-automation
> folks?) Thanks.

On EMBA, also git branches run the CI tests. See file test/infra/gitlab-ci.yml:

--8<---------------cut here---------------start------------->8---
    - if: '$CI_COMMIT_BRANCH !~ /^(master|emacs|feature|fix)/'
      when: never
--8<---------------cut here---------------end--------------->8---

So your branch name must start with one of these words.

Best regards, Michael.




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

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


Received: (at 54536) by debbugs.gnu.org; 24 Mar 2022 19:51:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Mar 24 15:51:09 2022
Received: from localhost ([127.0.0.1]:49455 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nXTUD-0005ia-Fn
	for submit <at> debbugs.gnu.org; Thu, 24 Mar 2022 15:51:09 -0400
Received: from mail-108-mta173.mxroute.com ([136.175.108.173]:40331)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jp@HIDDEN>) id 1nXTUC-0005iN-D4
 for 54536 <at> debbugs.gnu.org; Thu, 24 Mar 2022 15:51:08 -0400
Received: from filter006.mxroute.com ([140.82.40.27]
 140.82.40.27.vultrusercontent.com)
 (Authenticated sender: mN4UYu2MZsgR)
 by mail-108-mta173.mxroute.com (ZoneMTA) with ESMTPSA id
 17fbd7b7ad7000fe85.001 for <54536 <at> debbugs.gnu.org>
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256);
 Thu, 24 Mar 2022 19:51:00 +0000
X-Zone-Loop: fb6cc62911413ba4970da9bd9c13a9ec482b73e80e1f
X-Originating-IP: [140.82.40.27]
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:In-Reply-To:Date:References:
 Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID:
 Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
 :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:
 List-Post:List-Owner:List-Archive;
 bh=yYGJLZrn7srvOtgd/YvPcFGNLLDMCAb2qZi+j7Ev89I=; b=jmLhLEE9K0RW1iDj5twwGYjbz6
 4KrNXaLb+LSe8x/yPC6LvzFvOWzNuN9vmv0ogKXCx0muemptO/TAFH0e9VF7eluVl3ZlGM4TBctvm
 naOdaEPT4KeZMoutyL3S/uQV9sLl2ojg15a4pxXHX3SLr2HZxgqSnG9mXP7I23B3qBiZ5Z2U6XG8P
 h130IXf3S7Kn2nxBWuRzxfgz1v46QkYKskU9ZXxlOy2CMUaRSALmhCQmhX65miqRpP4ytO+kHAPJ1
 YfCCxIWrA2LrItJfiCQH7eo2cFjHuJoaZzdTMF1H/xvu0mJCplzwUj2MuYHTen50L0w8Urpnqzp61
 pbalW6UQ==;
From: "J.P." <jp@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN> <87czic93sa.fsf@HIDDEN>
Date: Thu, 24 Mar 2022 12:50:57 -0700
In-Reply-To: <87czic93sa.fsf@HIDDEN> (Lars Ingebrigtsen's message of "Wed,
 23 Mar 2022 14:50:13 +0100")
Message-ID: <87ee2rb04e.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-AuthUser: masked@HIDDEN
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 54536
Cc: emacs-erc@HIDDEN, 54536 <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 (-)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> "J.P." <jp@HIDDEN> writes:
>
>> 1. What should happen when a user submits multiline input containing
>>    empty lines? [...] This patch says [...]
>
> Makes sense to me.
>
>> 2. Should trailing blank lines be treated differently? [...]
>>
> Dropping trailing blank lines is a good thing, I think.
>
>> 3. When `erc-send-whitespace-lines' is non-nil, should it [...]
>>    This patch says no to the first and yes to the second.
>
> Sounds good.

Appreciate the feedback!

I'd like to get #48598 ("buffer-naming collisions involving bouncers in
ERC") up to snuff relatively soon. Would it make sense to petition
emacs-devel for eyeballs at some point? Also, is there any way to try
out some patches on EMBA CI? I have a feeling some of my tests that work
locally and on GitLab.com's GCP runners may have to be tuned a bit for
EMBA. (Or would these questions be better put to the build-automation
folks?) Thanks.




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

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


Received: (at 54536) by debbugs.gnu.org; 23 Mar 2022 13:50:26 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Mar 23 09:50:26 2022
Received: from localhost ([127.0.0.1]:43187 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nX1Na-0006gx-2A
	for submit <at> debbugs.gnu.org; Wed, 23 Mar 2022 09:50:26 -0400
Received: from quimby.gnus.org ([95.216.78.240]:46448)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1nX1NY-0006gj-4d
 for 54536 <at> debbugs.gnu.org; Wed, 23 Mar 2022 09:50:24 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:
 References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=ew+btwU4R6an/Ugi6pTomFQm6pgBRzaPCrbDnarKCU0=; b=nN/vvppDbECHIFkjBRu7ixlDcv
 Ehj/kB3YFb4885nGz//QMW2wBom6t3XqMlzY+aPds0BaHHfSPDXtCuVFEHO0vuq/Z98Djrnfrd3jg
 WuHZmtPF+ooLvgSjVNJ3YNSCJE7KR004vx3hlemYKiZWY/j6ZYxiyakke+VFZIT5GLJc=;
Received: from 109.179.236.69.tmi.telenormobil.no ([109.179.236.69] helo=xo)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1nX1NO-0004IQ-Hh; Wed, 23 Mar 2022 14:50:16 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: "J.P." <jp@HIDDEN>
Subject: Re: bug#54536: 29.0.50; Improve ERC's handling of multiline prompt
 input
References: <87k0ckg5pn.fsf@HIDDEN>
Date: Wed, 23 Mar 2022 14:50:13 +0100
In-Reply-To: <87k0ckg5pn.fsf@HIDDEN> (J. P.'s message of "Wed, 23 Mar
 2022 06:26:44 -0700")
Message-ID: <87czic93sa.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: "J.P." <jp@HIDDEN> writes: > 1. What should happen when
 a user submits multiline input containing > empty lines? Should these be
 padded so they're not rejected by the > server? If so, where in the processing
 pipeline should tha [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 0.0 TVD_RCVD_IP            Message was received from an IP address
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 54536
Cc: emacs-erc@HIDDEN, 54536 <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 (---)

"J.P." <jp@HIDDEN> writes:

> 1. What should happen when a user submits multiline input containing
>    empty lines? Should these be padded so they're not rejected by the
>    server? If so, where in the processing pipeline should that occur?
>    Should `erc-send-whitespace-lines' play a role here?
>
>    This patch says yes to the latter and interprets that option as
>    meaning "preserve whitespace-only lines and create them as necessary
>    from blank ones." As to where padding should happen, this patch punts
>    and retains the existing (unfortunate) practice of treating them at
>    the last minute.

Makes sense to me.

> 2. Should trailing blank lines be treated differently? If so, how?
>    Should they be auto-padded? Simply dropped? Or should encountering
>    them raise an error?
>
>    When `erc-send-whitespace-lines' is non-nil, this patch drops
>    trailing blanks by default, but it also provides an escape hatch.

Dropping trailing blank lines is a good thing, I think.

> 3. When `erc-send-whitespace-lines' is non-nil, should it auto-pad a
>    submission consisting of a single empty line? Should it allow a
>    whitespace-only singleton through?
>
>    This patch says no to the first and yes to the second.

Sounds good.

> 4. Should slash commands, like /MSG be allowed to lead a multiline
>    submission?
>
>    This patch says no, still choosing to interpret commands as always
>    consisting of a single line.

Ditto.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

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


Received: (at submit) by debbugs.gnu.org; 23 Mar 2022 13:27:01 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Mar 23 09:27:01 2022
Received: from localhost ([127.0.0.1]:43137 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nX10t-0001ft-NF
	for submit <at> debbugs.gnu.org; Wed, 23 Mar 2022 09:27:01 -0400
Received: from lists.gnu.org ([209.51.188.17]:50042)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jp@HIDDEN>) id 1nX10r-0001fk-5k
 for submit <at> debbugs.gnu.org; Wed, 23 Mar 2022 09:26:58 -0400
Received: from eggs.gnu.org ([209.51.188.92]:46828)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <jp@HIDDEN>) id 1nX10q-0001ma-Ae
 for bug-gnu-emacs@HIDDEN; Wed, 23 Mar 2022 09:26:57 -0400
Received: from mail-108-mta94.mxroute.com ([136.175.108.94]:34415)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <jp@HIDDEN>) id 1nX10m-0007b7-8j
 for bug-gnu-emacs@HIDDEN; Wed, 23 Mar 2022 09:26:56 -0400
Received: from filter006.mxroute.com ([140.82.40.27]
 140.82.40.27.vultrusercontent.com)
 (Authenticated sender: mN4UYu2MZsgR)
 by mail-108-mta94.mxroute.com (ZoneMTA) with ESMTPSA id 17fb6f55b21000fe85.001
 for <bug-gnu-emacs@HIDDEN>
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES128-GCM-SHA256);
 Wed, 23 Mar 2022 13:26:47 +0000
X-Zone-Loop: bfd407eab9988c48a665033a0c3fa039fb83f4271dea
X-Originating-IP: [140.82.40.27]
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: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:In-Reply-To:
 References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:
 List-Owner:List-Archive; bh=0lJyincDSBojSRdaYrPT/7AqudF21vOkESzXWkaQS5U=; b=U
 r3zVcuR2BT7AdjpaFmsG9O2m9m2ot8EDDQg5SnZLSa5lseuKewKxg4WeHW3FfnU+hMASKi7f/0p0j
 fj6+Z+s/o3HmyYaAgwh0eekA5p3bsEpqNbaD4jOdA/pbmqJP3mN5DONX2QAzMA8/yrWfzYWllLPzH
 QZR6XvLYDaWbvwVKuw9ozNe27YbleN5HohHIX2DGY+saTh9W4bmOEUMaerN07ZvMS5NFMRIBPIp58
 Ohl7Yajd0r95gaIWbubUEBkJ46Lp+XUWasZt1EDmxEEjNFWY3xcHHa62Gm1bsq8kS74EVAGTaiprf
 m5cIHfo+JSayl8spfOwWBZdsA/LDgnTCg==;
From: "J.P." <jp@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 29.0.50; Improve ERC's handling of multiline prompt input
Date: Wed, 23 Mar 2022 06:26:44 -0700
Message-ID: <87k0ckg5pn.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-AuthUser: masked@HIDDEN
Received-SPF: pass client-ip=136.175.108.94; envelope-from=jp@HIDDEN;
 helo=mail-108-mta94.mxroute.com
X-Spam_score_int: -16
X-Spam_score: -1.7
X-Spam_bar: -
X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, DKIM_INVALID=0.1,
 DKIM_SIGNED=0.1, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.4 (-)
X-Debbugs-Envelope-To: submit
Cc: emacs-erc@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

--=-=-=
Content-Type: text/plain

Tags: patch

ERC suffers from a few related issues concerning the early handling of
user input at the prompt. Especially troublesome is "multiline" input
containing line feeds and/or carriage returns. This patch (or at least
this discussion) aims to tackle both.

Any solution should probably address these fundamental UX questions:

1. What should happen when a user submits multiline input containing
   empty lines? Should these be padded so they're not rejected by the
   server? If so, where in the processing pipeline should that occur?
   Should `erc-send-whitespace-lines' play a role here?

   This patch says yes to the latter and interprets that option as
   meaning "preserve whitespace-only lines and create them as necessary
   from blank ones." As to where padding should happen, this patch punts
   and retains the existing (unfortunate) practice of treating them at
   the last minute.

2. Should trailing blank lines be treated differently? If so, how?
   Should they be auto-padded? Simply dropped? Or should encountering
   them raise an error?

   When `erc-send-whitespace-lines' is non-nil, this patch drops
   trailing blanks by default, but it also provides an escape hatch.

3. When `erc-send-whitespace-lines' is non-nil, should it auto-pad a
   submission consisting of a single empty line? Should it allow a
   whitespace-only singleton through?

   This patch says no to the first and yes to the second.

4. Should slash commands, like /MSG be allowed to lead a multiline
   submission?

   This patch says no, still choosing to interpret commands as always
   consisting of a single line.

To offer some flexibility, I'm introducing a hook to perform some
validation on the input being submitted. It comes prepopulated with
functions that replicate existing behavior, such as ensuring point
resides within the input area. It also contains an additional function
to perform the blank-detection business. While it's true that multiple
members of this hook may end up repeating some basic operations (such as
splitting the input string), at present, this isn't the case, and such
waste is pretty negligible anyway since this is an interactive function.

There is one behavioral change being introduced that doesn't come
with an escape hatch, and that's the preservation of input when
a validation check fails. Previously, a user's input would be wiped
out, which seems undesirable and unnecessary in all cases (IMO).

For these and any other, less significant changes not mentioned, the
floor is open for questions and debate, as usual. Thanks.

(See also: "bug#50008: 28.0.50; ERC sends empty lines with user input"
and "bug#50006: 28.0.50; remove deprecated option erc-send-pre-hook".)


In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.31, cairo version 1.17.4)
 of 2022-03-23 built on localhost
Repository revision: fed9a353dbe79a7a6acc74c1e223c46e7541e627
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12014000
System Description: Fedora Linux 35 (Workstation Edition)

Configured using:
 'configure --enable-check-lisp-object-type --enable-checking=yes,glyphs
 'CFLAGS=-O0 -g3'
 PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY
INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS WEBP X11 XDBE XIM XPM GTK3 ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message mailcap yank-media rmc puny
dired dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg
rfc6068 epg-config gnus-util text-property-search time-date seq gv
subr-x byte-opt bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
iso-transl tooltip eldoc paren electric uniquify ediff-hook vc-hooks
lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd
tool-bar dnd fontset image regexp-opt fringe tabulated-list replace
newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar
rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock
font-lock syntax font-core term/tty-colors frame minibuffer nadvice
simple cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan
thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian
slovak czech european ethiopic indian cyrillic chinese composite
emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help
abbrev obarray cl-preloaded button loaddefs faces cus-face macroexp
files window text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget keymap hashtable-print-readable backquote
threads dbusbind inotify lcms2 dynamic-setting system-font-setting
font-render-setting cairo move-toolbar gtk x-toolkit x multi-tty
make-network-process emacs)

Memory information:
((conses 16 43960 5198)
 (symbols 48 5704 1)
 (strings 32 15802 1589)
 (string-bytes 1 526831)
 (vectors 16 12066)
 (vector-slots 8 167842 8149)
 (floats 8 20 55)
 (intervals 56 241 0)
 (buffers 992 11))

--=-=-=
Content-Type: text/x-patch
Content-Disposition: attachment;
 filename=0001-Fix-regression-in-erc-send-input-line.patch

From fe1f21eeb9027116f263b968d792943b92064df3 Mon Sep 17 00:00:00 2001
From: "F. Jason Park" <jp@HIDDEN>
Date: Mon, 21 Mar 2022 19:21:57 -0700
Subject: [PATCH 1/2] Fix regression in erc-send-input-line

* lisp/erc/erc.el (erc-send-input-line): Restore remedial single-space
padding to ensure empty messages typed at the prompt without an
explicit /msg aren't rejected by the server.  This behavior is only
noticeable when `erc-send-whitespace-lines' is active.

* test/lisp/erc/erc-tests.el (erc-process-input-line): Add trailing
newline to more correctly simulate how it's actually called by
`erc-send-input'. (Bug#50008)
---
 lisp/erc/erc.el            |  2 ++
 test/lisp/erc/erc-tests.el | 10 +++++-----
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el
index 52fe106f2d..d8ef62cf93 100644
--- a/lisp/erc/erc.el
+++ b/lisp/erc/erc.el
@@ -2817,6 +2817,8 @@ erc-send-input-line-function
 
 (defun erc-send-input-line (target line &optional force)
   "Send LINE to TARGET."
+  (when (string= line "\n")
+    (setq line " \n"))
   (erc-message "PRIVMSG" (concat target " " line) force))
 
 (defun erc-get-arglist (fun)
diff --git a/test/lisp/erc/erc-tests.el b/test/lisp/erc/erc-tests.el
index 520f10dd4e..10e3c16dfc 100644
--- a/test/lisp/erc/erc-tests.el
+++ b/test/lisp/erc/erc-tests.el
@@ -340,19 +340,19 @@ erc-process-input-line
         (ert-info ("Implicit cmd via `erc-send-input-line-function'")
 
           (ert-info ("Baseline")
-            (erc-process-input-line "hi")
+            (erc-process-input-line "hi\n")
             (should (equal (pop erc-server-flood-queue)
                            '("PRIVMSG #chan :hi\r\n" . utf-8))))
 
           (ert-info ("Spaces preserved")
-            (erc-process-input-line "hi you")
+            (erc-process-input-line "hi you\n")
             (should (equal (pop erc-server-flood-queue)
                            '("PRIVMSG #chan :hi you\r\n" . utf-8))))
 
-          (ert-info ("Empty line transmitted without injected-space kludge")
-            (erc-process-input-line "")
+          (ert-info ("Empty line transmitted with injected-space kludge")
+            (erc-process-input-line "\n")
             (should (equal (pop erc-server-flood-queue)
-                           '("PRIVMSG #chan :\r\n" . utf-8))))
+                           '("PRIVMSG #chan : \r\n" . utf-8))))
 
           (should-not calls))))))
 
-- 
2.35.1


--=-=-=
Content-Type: text/x-patch
Content-Disposition: attachment;
 filename=0002-Improve-ERC-s-handling-of-multiline-prompt-input.patch

From 8a921612bdafdc5720fe12b49d215c1a42f9c0d0 Mon Sep 17 00:00:00 2001
From: "F. Jason Park" <jp@HIDDEN>
Date: Mon, 21 Mar 2022 05:40:16 -0700
Subject: [PATCH 2/2] Improve ERC's handling of multiline prompt input

* lisp/erc/erc.el (erc-pre-send-functions,
erc-discard-trailing-multiline-nulls): Add the latter, a new function,
that drops any trailing null lines from a multiline sequence submitted
for processing.  Add it to `erc-pre-send-functions' as the lone new
default.
(erc-last-input-time): Tweak meaning of variable to match likely
original intent, which is that it's only updated on successful calls
to `erc-send-current-line'.
(erc--input-line-delim-regexp): Add regex var for splitting multiline
prompt input.
(erc--blank-in-multiline-p): Add helper for detecting blank lines.
(erc-check-prompt-input-for-multiline-blanks,
erc-check-prompt-input-for-point-in-bounds,
erc-check-prompt-input-for-running-process): New functions to
encapsulate logic for various pre-flight idiot checks.
(erc-check-prompt-input-functions): Add new hook for validating prompt
input prior to clearing it.
(erc-send-current-line): pre-screen for blank lines and bail out if
necessary.
(erc-send-input): Add optional param to skip
checking for blank lines.

* test/lisp/erc/erc-tests.el (erc-ring-previous-command): Use new test
helper.
(erc--input-line-delim-regexp,
erc--blank-in-multiline-input-p): Add tests.
(erc-tests--send-prep, erc-tests--set-fake-server-process,
erc-tests--with-process-input-spy): Add test helpers.
(erc-check-prompt-input-functions, erc-send-current-line,
erc-send-whitespace-lines): Add tests.
---
 lisp/erc/erc.el            | 103 ++++++++++++++-----
 test/lisp/erc/erc-tests.el | 200 +++++++++++++++++++++++++++++++++++--
 2 files changed, 273 insertions(+), 30 deletions(-)

diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el
index d8ef62cf93..cbb30bab5b 100644
--- a/lisp/erc/erc.el
+++ b/lisp/erc/erc.el
@@ -1040,7 +1040,7 @@ erc-send-pre-hook
   :type 'hook)
 (make-obsolete-variable 'erc-send-pre-hook 'erc-pre-send-functions "27.1")
 
-(defcustom erc-pre-send-functions nil
+(defcustom erc-pre-send-functions '(erc-discard-trailing-multiline-nulls)
   "Special hook run to possibly alter the string that is sent.
 The functions are called with one argument, an `erc-input' struct,
 and should alter that struct.
@@ -5536,7 +5536,7 @@ erc-end-of-input-line
   (point-max))
 
 (defvar erc-last-input-time 0
-  "Time of last call to `erc-send-current-line'.
+  "Time of last successful call to `erc-send-current-line'.
 If that function has never been called, the value is 0.")
 
 (defcustom erc-accidental-paste-threshold-seconds 0.2
@@ -5552,6 +5552,66 @@ erc-accidental-paste-threshold-seconds
   :version "26.1"
   :type '(choice number (other :tag "disabled" nil)))
 
+(defvar erc--input-line-delim-regexp (rx (| (: (? ?\r) ?\n) ?\r)))
+
+(defun erc--blank-in-multiline-input-p (string)
+  "Detect whether STRING contains any blank lines.
+When `erc-send-whitespace-lines' is in effect and the input is not a
+\"command\", like /msg, return nil if the input is multiline or the line
+is non-empty.  When `erc-send-whitespace-lines' is nil, return non-nil
+when any line is empty or consists of one or more spaces, tabs, or
+form-feeds."
+  (catch 'return
+    (let ((lines (split-string string erc--input-line-delim-regexp))
+          (cmdp '--?--))
+      (dolist (line lines)
+        (when (if erc-send-whitespace-lines
+                  (and (string= line "")
+                       (or (null (cdr lines)) ; string is one line
+                           (if (eq cmdp '--?--) ; string is /cmd
+                               (setq cmdp (string-match erc-command-regexp
+                                                        (car lines)))
+                             cmdp)))
+                (string-match (rx bot (* (in " \t\f")) eot) line))
+          (throw 'return t))))))
+
+(defun erc-discard-trailing-multiline-nulls (state)
+  "Ensure last line of `erc-input' STATE's string is non-null.
+But only when `erc-send-whitespace-lines' is non-nil."
+  (when erc-send-whitespace-lines
+    (cl-callf (lambda (s) (string-trim-right s "[\r\n]+"))
+        (erc-input-string state))))
+
+(defun erc-check-prompt-input-for-multiline-blanks (string)
+  "Return non-nil when multiline prompt input has blank lines."
+  (when (erc--blank-in-multiline-input-p string)
+    (if erc-warn-about-blank-lines
+        "Blank line - ignoring..."
+      'invalid)))
+
+(defun erc-check-prompt-input-for-point-in-bounds (_)
+  "Return non-nil when point is before prompt."
+  (when (< (point) (erc-beg-of-input-line))
+    "Point is not in the input area"))
+
+(defun erc-check-prompt-input-for-running-process (string)
+  "Return non-nil unless in an active ERC server buffer."
+  (unless (or (erc-server-buffer-live-p)
+              (erc-command-no-process-p string))
+    "ERC: No process running"))
+
+(defcustom erc-check-prompt-input-functions
+  '(erc-check-prompt-input-for-point-in-bounds
+    erc-check-prompt-input-for-multiline-blanks
+    erc-check-prompt-input-for-running-process)
+  "Validators for user input typed at prompt.
+Called with latest input string submitted by user.  If any member
+returns non-nil, processing is abandoned and input is left untouched.
+When the returned value is a string, pass it to `erc-error'."
+  :group 'erc
+  :version "29.1"
+  :type 'hook)
+
 (defun erc-send-current-line ()
   "Parse current line and send it to IRC."
   (interactive)
@@ -5565,20 +5625,20 @@ erc-send-current-line
                      (eolp))
             (expand-abbrev))
           (widen)
-          (if (< (point) (erc-beg-of-input-line))
-              (erc-error "Point is not in the input area")
+          (if-let* ((str (erc-user-input))
+                    (msg (run-hook-with-args-until-success
+                          'erc-check-prompt-input-functions str)))
+              (when (stringp msg)
+                (erc-error msg))
             (let ((inhibit-read-only t)
-                  (str (erc-user-input))
                   (old-buf (current-buffer)))
-              (if (and (not (erc-server-buffer-live-p))
-                       (not (erc-command-no-process-p str)))
-                  (erc-error "ERC: No process running")
+              (progn ; unprogn this during next major surgery
                 (erc-set-active-buffer (current-buffer))
                 ;; Kill the input and the prompt
                 (delete-region (erc-beg-of-input-line)
                                (erc-end-of-input-line))
                 (unwind-protect
-                    (erc-send-input str)
+                    (erc-send-input str 'skip-ws-chk)
                   ;; Fix the buffer if the command didn't kill it
                   (when (buffer-live-p old-buf)
                     (with-current-buffer old-buf
@@ -5593,8 +5653,8 @@ erc-send-current-line
                           (set-buffer-modified-p buffer-modified))))))
 
                 ;; Only when last hook has been run...
-                (run-hook-with-args 'erc-send-completed-hook str))))
-          (setq erc-last-input-time now))
+                (run-hook-with-args 'erc-send-completed-hook str)))
+            (setq erc-last-input-time now)))
       (switch-to-buffer "*ERC Accidental Paste Overflow*")
       (lwarn 'erc :warning
              "You seem to have accidentally pasted some text!"))))
@@ -5611,21 +5671,16 @@ erc-command-regexp
 (cl-defstruct erc-input
   string insertp sendp)
 
-(defun erc-send-input (input)
+(defun erc-send-input (input &optional skip-ws-chk)
   "Treat INPUT as typed in by the user.
 It is assumed that the input and the prompt is already deleted.
 Return non-nil only if we actually send anything."
   ;; Handle different kinds of inputs
-  (cond
-   ;; Ignore empty input
-   ((if erc-send-whitespace-lines
-        (string= input "")
-      (string-match "\\`[ \t\r\f\n]*\\'" input))
-    (when erc-warn-about-blank-lines
-      (message "Blank line - ignoring...")
-      (beep))
-    nil)
-   (t
+  (if (and (not skip-ws-chk)
+           (erc-check-prompt-input-for-multiline-blanks input))
+      (when erc-warn-about-blank-lines
+        (message "Blank line - ignoring...") ; compat
+        (beep))
     ;; This dynamic variable is used by `erc-send-pre-hook'.  It's
     ;; obsolete, and when it's finally removed, this binding should
     ;; also be removed.
@@ -5663,9 +5718,9 @@ erc-send-input
                                             (null erc-flood-protect) t))
                   (or (and erc-flood-protect (erc-split-line line))
                       (list line))))
-               (split-string string "\n"))
+               (split-string string erc--input-line-delim-regexp))
             (erc-process-input-line (concat string "\n") t nil))
-          t))))))
+          t)))))
 
 ;; (defun erc-display-command (line)
 ;;   (when erc-insert-this
diff --git a/test/lisp/erc/erc-tests.el b/test/lisp/erc/erc-tests.el
index 10e3c16dfc..6a9d291f8a 100644
--- a/test/lisp/erc/erc-tests.el
+++ b/test/lisp/erc/erc-tests.el
@@ -197,14 +197,10 @@ erc-ring-previous-command-base-case
 (ert-deftest erc-ring-previous-command ()
   (with-current-buffer (get-buffer-create "*#fake*")
     (erc-mode)
-    (insert "\n\n")
+    (erc-tests--send-prep)
+    (setq-local erc-last-input-time 0)
     (should-not (local-variable-if-set-p 'erc-send-completed-hook))
     (set (make-local-variable 'erc-send-completed-hook) nil) ; skip t (globals)
-    (setq erc-input-marker (make-marker)
-          erc-insert-marker (make-marker))
-    (set-marker erc-insert-marker (point-max))
-    (erc-display-prompt)
-    (should (= (point) erc-input-marker))
     ;; Just in case erc-ring-mode is already on
     (setq-local erc-pre-send-functions nil)
     (add-hook 'erc-pre-send-functions #'erc-add-to-input-ring)
@@ -285,6 +281,198 @@ erc-log-irc-protocol
     (kill-buffer "*erc-protocol*")
     (should-not erc-debug-irc-protocol)))
 
+(ert-deftest erc--input-line-delim-regexp ()
+  (let ((p erc--input-line-delim-regexp))
+    ;; none
+    (should (equal '("a" "b") (split-string "a\r\nb" p)))
+    (should (equal '("a" "b") (split-string "a\nb" p)))
+    (should (equal '("a" "b") (split-string "a\rb" p)))
+
+    ;; one
+    (should (equal '("") (split-string "" p)))
+    (should (equal '("a" "" "b") (split-string "a\r\rb" p)))
+    (should (equal '("a" "" "b") (split-string "a\n\rb" p)))
+    (should (equal '("a" "" "b") (split-string "a\n\nb" p)))
+    (should (equal '("a" "" "b") (split-string "a\r\r\nb" p)))
+    (should (equal '("a" "" "b") (split-string "a\n\r\nb" p)))
+    (should (equal '("a" "") (split-string "a\n" p)))
+    (should (equal '("a" "") (split-string "a\r" p)))
+    (should (equal '("a" "") (split-string "a\r\n" p)))
+    (should (equal '("" "b") (split-string "\nb" p)))
+    (should (equal '("" "b") (split-string "\rb" p)))
+    (should (equal '("" "b") (split-string "\r\nb" p)))
+
+    ;; two
+    (should (equal '("" "") (split-string "\r" p)))
+    (should (equal '("" "") (split-string "\n" p)))
+    (should (equal '("" "") (split-string "\r\n" p)))
+
+    ;; three
+    (should (equal '("" "" "") (split-string "\r\r" p)))
+    (should (equal '("" "" "") (split-string "\n\n" p)))
+    (should (equal '("" "" "") (split-string "\n\r" p)))))
+
+(ert-deftest erc--blank-in-multiline-input-p ()
+  (ert-info ("With `erc-send-whitespace-lines'")
+    (let ((erc-send-whitespace-lines t))
+      (should (erc--blank-in-multiline-input-p ""))
+      (should (erc--blank-in-multiline-input-p "/msg a\n")) ; likely oops
+      (should (erc--blank-in-multiline-input-p "/msg a\n\nb")) ; "" not allowed
+      (should-not (erc--blank-in-multiline-input-p "a\n\nb")) ; "" allowed
+      (should-not (erc--blank-in-multiline-input-p " "))
+      (should-not (erc--blank-in-multiline-input-p "\t"))
+      (should-not (erc--blank-in-multiline-input-p "a\nb"))
+      (should-not (erc--blank-in-multiline-input-p "a\n "))
+      (should-not (erc--blank-in-multiline-input-p "a\n \t"))
+      (should-not (erc--blank-in-multiline-input-p "a\n \f"))
+      (should-not (erc--blank-in-multiline-input-p "a\n \nb"))
+      (should-not (erc--blank-in-multiline-input-p "a\n \t\nb"))
+      (should-not (erc--blank-in-multiline-input-p "a\n \f\nb"))))
+
+  (should (erc--blank-in-multiline-input-p ""))
+  (should (erc--blank-in-multiline-input-p " "))
+  (should (erc--blank-in-multiline-input-p "\t"))
+  (should (erc--blank-in-multiline-input-p "a\n\nb"))
+  (should (erc--blank-in-multiline-input-p "a\n\nb"))
+  (should (erc--blank-in-multiline-input-p "a\n "))
+  (should (erc--blank-in-multiline-input-p "a\n \t"))
+  (should (erc--blank-in-multiline-input-p "a\n \f"))
+  (should (erc--blank-in-multiline-input-p "a\n \nb"))
+  (should (erc--blank-in-multiline-input-p "a\n \t\nb"))
+
+  (should-not (erc--blank-in-multiline-input-p "a\rb"))
+  (should-not (erc--blank-in-multiline-input-p "a\nb"))
+  (should-not (erc--blank-in-multiline-input-p "a\r\nb")))
+
+(defun erc-tests--send-prep ()
+  (erc-mode)
+  (insert "\n\n")
+  (setq erc-input-marker (make-marker)
+        erc-insert-marker (make-marker))
+  (set-marker erc-insert-marker (point-max))
+  (erc-display-prompt)
+  (should (= (point) erc-input-marker)))
+
+(defun erc-tests--set-fake-server-process (&rest args)
+  (setq erc-server-process
+        (apply #'start-process (car args) (current-buffer) args))
+  (set-process-query-on-exit-flag erc-server-process nil))
+
+(defmacro erc-tests--with-process-input-spy (calls-var &rest body)
+  (declare (indent 1))
+  `(with-current-buffer (get-buffer-create "FakeNet")
+     (let ((erc-pre-send-functions
+            (remove #'erc-add-to-input-ring erc-pre-send-functions)) ; for now
+           (inhibit-message noninteractive)
+           (erc-server-current-nick "tester")
+           (erc-last-input-time 0)
+           erc-accidental-paste-threshold-seconds
+           ,calls-var)
+       (cl-letf (((symbol-function 'erc-process-input-line)
+                  (lambda (&rest r) (push r ,calls-var)))
+                 ((symbol-function 'erc-server-buffer)
+                  (lambda () (current-buffer))))
+         (erc-tests--send-prep)
+         ,@body))
+     (when noninteractive (kill-buffer))))
+
+(ert-deftest erc-check-prompt-input-functions ()
+  (erc-tests--with-process-input-spy calls
+
+    (ert-info ("Errors when point not in prompt area") ; actually just dings
+      (insert "/msg #chan hi")
+      (forward-line -1)
+      (let ((e (should-error (erc-send-current-line))))
+        (should (equal "Point is not in the input area" (cadr e))))
+      (goto-char (point-max))
+      (ert-info ("Input remains untouched")
+        (should (save-excursion (erc-bol) (looking-at "/msg #chan hi")))))
+
+    (ert-info ("Errors when no process running")
+      (let ((e (should-error (erc-send-current-line))))
+        (should (equal "ERC: No process running" (cadr e))))
+      (ert-info ("Input remains untouched")
+        (should (save-excursion (erc-bol) (looking-at "/msg #chan hi")))))
+
+    (ert-info ("Errors when line contains empty newline")
+      (erc-bol)
+      (delete-region (point) (point-max))
+      (insert "one\n")
+      (let ((e (should-error (erc-send-current-line))))
+        (should (equal "Blank line - ignoring..." (cadr e))))
+      (goto-char (point-max))
+      (ert-info ("Input remains untouched")
+        (should (save-excursion (goto-char erc-input-marker)
+                                (looking-at "one\n")))))
+
+    (should (= 0 erc-last-input-time))
+    (should-not calls)))
+
+;; These also indirectly tests `erc-send-input'
+
+(ert-deftest erc-send-current-line ()
+  (erc-tests--with-process-input-spy calls
+
+    (erc-tests--set-fake-server-process "sleep" "1")
+    (should (= 0 erc-last-input-time))
+
+    (ert-info ("Simple command")
+      (insert "/msg #chan hi")
+      (erc-send-current-line)
+      (ert-info ("Prompt restored")
+        (forward-line 0)
+        (should (looking-at-p erc-prompt)))
+      (ert-info ("Input cleared")
+        (erc-bol)
+        (should (eq (point) (point-max))))
+      ;; Commands are forced (no flood protection)
+      (should (equal (pop calls) '("/msg #chan hi\n" t nil))))
+
+    (ert-info ("Simple non-command")
+      (insert "hi")
+      (erc-send-current-line)
+      (should (eq (point) (point-max)))
+      (should (save-excursion (forward-line -1)
+                              (search-forward "<tester> hi")))
+      ;; Non-ommands are forced only when `erc-flood-protect' is nil
+      (should (equal (pop calls) '("hi\n" nil t))))
+
+    (should (consp erc-last-input-time))))
+
+(ert-deftest erc-send-whitespace-lines ()
+  (erc-tests--with-process-input-spy calls
+
+    (erc-tests--set-fake-server-process "sleep" "1")
+    (setq-local erc-send-whitespace-lines t)
+
+    (ert-info ("Multiline hunk with blank line correctly split")
+      (insert "one\n\ntwo")
+      (erc-send-current-line)
+      (ert-info ("Prompt restored")
+        (forward-line 0)
+        (should (looking-at-p erc-prompt)))
+      (ert-info ("Input cleared")
+        (erc-bol)
+        (should (eq (point) (point-max))))
+      (should (equal (pop calls) '("two\n" nil t)))
+      (should (equal (pop calls) '("\n" nil t)))
+      (should (equal (pop calls) '("one\n" nil t))))
+
+    (ert-info ("Multiline hunk with trailing blank filtered")
+      (insert "hi\n")
+      (erc-send-current-line)
+      (ert-info ("Input cleared")
+        (erc-bol)
+        (should (eq (point) (point-max))))
+      (should (equal (pop calls) '("hi\n" nil t)))
+      (should-not (pop calls)))
+
+    (ert-info ("Multiline hunk with trailing whitespace not filtered")
+      (insert "there\n ")
+      (erc-send-current-line)
+      (should (equal (pop calls) '(" \n" nil t)))
+      (should (equal (pop calls) '("there\n" nil t)))
+      (should-not (pop calls)))))
 
 ;; The point of this test is to ensure output is handled identically
 ;; regardless of whether a command handler is summoned.
-- 
2.35.1


--=-=-=--




Acknowledgement sent to "J.P." <jp@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#54536; 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, 26 Mar 2022 16:45:02 UTC

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