From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rupert Gallagher Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Fri, 14 Feb 2025 17:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 76290@debbugs.gnu.org X-Debbugs-Original-To: "bug-coreutils@gnu.org" Received: via spool by submit@debbugs.gnu.org id=B.17395524046971 (code B ref -1); Fri, 14 Feb 2025 17:01:01 +0000 Received: (at submit) by debbugs.gnu.org; 14 Feb 2025 17:00:04 +0000 Received: from localhost ([127.0.0.1]:51439 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tiz2m-0001nI-FO for submit@debbugs.gnu.org; Fri, 14 Feb 2025 12:00:04 -0500 Received: from lists.gnu.org ([2001:470:142::17]:58422) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tixs4-0006fJ-H0 for submit@debbugs.gnu.org; Fri, 14 Feb 2025 10:44:54 -0500 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 1tixry-0008PF-68 for bug-coreutils@gnu.org; Fri, 14 Feb 2025 10:44:46 -0500 Received: from mail-40141.protonmail.ch ([185.70.40.141]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tixrw-0003tv-Aw for bug-coreutils@gnu.org; Fri, 14 Feb 2025 10:44:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739547879; x=1739807079; bh=+4y3Uj6TIVd5mE+Jagsq85sYFUdjCw9MVodtdx7bI4k=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector: List-Unsubscribe:List-Unsubscribe-Post; b=vRNyBx6ErgHq/t9s9gdspvxvqmpaJXuzwXN3zQ03w6uDMamsZB8Ihwvxzx2Vlj6pp 5vEb3TDiTSdFNB5y/8Y68uJWuN41ysLwaUkZENi7Ky/vCiVijvetuTobco5w1NabRM cD+IIypQsuh+VVjU4yxdDj/DggGN1PGF50h2V+7IxBzK4XmQKM9zdu64zSBxQ7bqkW Jn1TwnGQd/K0DusTHKEdawjGc6554SJyllbg83rGTaErZ10/np6qlahEzKET4tDmIV 27mkqdX0/18w2+3qRu1VRqZYMCTBRvihfyEcpfyc9rUUs8FM5plJSN7jcV7e73O4S+ rsLexDyPr+WDw== Date: Fri, 14 Feb 2025 15:44:34 +0000 From: Rupert Gallagher Message-ID: Feedback-ID: 945109:user:proton X-Pm-Message-ID: 01bfb0e1c1ed4a52f265069d7a283ca11d51766c MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU" Received-SPF: pass client-ip=185.70.40.141; envelope-from=ruga@protonmail.com; helo=mail-40141.protonmail.ch 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, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Mailman-Approved-At: Fri, 14 Feb 2025 11:59:58 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: base64 PmVjaG8gLWUgIkNWRS0yMDE4LTEzNzg3XG5DVkUtMjAxOS0xNjY0OVxuQ1ZFLTIwMTktMTY2NTBc bkNWRS0yMDIwLTE1MDQ2XG5DVkUtMjAxOC0xMzc4NyIKQ1ZFLTIwMTgtMTM3ODcgPC0tLQpDVkUt MjAxOS0xNjY0OQpDVkUtMjAxOS0xNjY1MApDVkUtMjAyMC0xNTA0NkNWRS0yMDE4LTEzNzg3IDwt LS0KCj5lY2hvIC1lICJDVkUtMjAxOC0xMzc4N1xuQ1ZFLTIwMTktMTY2NDlcbkNWRS0yMDE5LTE2 NjUwXG5DVkUtMjAyMC0xNTA0NlxuQ1ZFLTIwMTgtMTM3ODciIHwgc29ydApDVkUtMjAxOC0xMzc4 NyA8LS0tCkNWRS0yMDE4LTEzNzg3IDwtLS0KQ1ZFLTIwMTktMTY2NDkKQ1ZFLTIwMTktMTY2NTAK Q1ZFLTIwMjAtMTUwNDYKCj5lY2hvIC1lICJDVkUtMjAxOC0xMzc4N1xuQ1ZFLTIwMTktMTY2NDlc bkNWRS0yMDE5LTE2NjUwXG5DVkUtMjAyMC0xNTA0NlxuQ1ZFLTIwMTgtMTM3ODciIHwgc29ydCAt dQpDVkUtMjAxOC0xMzc4NyA8LS0tCkNWRS0yMDE5LTE2NjQ5CkNWRS0yMDE5LTE2NjUwCkNWRS0y MDIwLTE1MDQ2CgpQcm9ibGVtOgoKP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Byb3Rvbm1haWxfc2lnbmF0dXJlX2Jsb2Nr LXByb3RvbiBwcm90b25tYWlsX3NpZ25hdHVyZV9ibG9jay1lbXB0eSI+DQogICAgICAgIA0KICAg ICAgICAgICAgPC9kaXY+DQo8L2Rpdj4NCg== --b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU-- From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug References: In-Reply-To: Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Sun, 16 Feb 2025 06:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Rupert Gallagher Cc: 76290@debbugs.gnu.org Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173968704826828 (code B ref 76290); Sun, 16 Feb 2025 06:25:02 +0000 Received: (at 76290) by debbugs.gnu.org; 16 Feb 2025 06:24:08 +0000 Received: from localhost ([127.0.0.1]:59602 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tjY4W-0006ye-3G for submit@debbugs.gnu.org; Sun, 16 Feb 2025 01:24:08 -0500 Received: from mail.cs.ucla.edu ([131.179.128.66]:42278) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tjY4U-0006y4-0r for 76290@debbugs.gnu.org; Sun, 16 Feb 2025 01:24:06 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 6D1993C00E415; Sat, 15 Feb 2025 22:24:00 -0800 (PST) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id QYcBXe6qvyjK; Sat, 15 Feb 2025 22:24:00 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 352BB3C00E41C; Sat, 15 Feb 2025 22:24:00 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 352BB3C00E41C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1739687040; bh=xHqiY2aI5cgrH2te6FCrY9V0vnoik5pcCUW7d3xDMI0=; h=Message-ID:Date:MIME-Version:To:From; b=fi0RW2XF/3bh/lkP+dBV1rRQM/CjakKaeqpekcbjRj/Du9hIme/6BNzO9qVDZ3taT pCDA5D/+kWVSXhGyuIGOR11Q0JsdVfdiiQ76uUpcqZ5ndoWOB6cX10gcbXHsG9iEYj EuBynDBTbU7DX2pX3t94uosdKEUvPG3bgvgXTy24VrXDXVlPYp3Zeidlrrz/EbuFU4 yn7HQMaF319bc0fOpnYBu/HbpGdTZ554tuB4lQyf1+K2Lw55Ft1A0fhCp9/g2sN9U+ TyHlWk6SIM6T6srwifRE2qYWpNaxv0mZffLy6fwzNaGnDqZUWNv9W33ONX2EfBwM+T FFaYgbjDBhSOQ== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id hzjEIqrq3PSA; Sat, 15 Feb 2025 22:24:00 -0800 (PST) Received: from [192.168.254.12] (unknown [47.147.225.25]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 17C443C00E415; Sat, 15 Feb 2025 22:24:00 -0800 (PST) Message-ID: Date: Sat, 15 Feb 2025 22:23:59 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) I don't see a bug there, just an infelicity. -h means 'sort' should look for a number, and your data lines don't start with numbers. Try 'sort --debug -h -u' to see more. From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rupert Gallagher Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Sun, 16 Feb 2025 15:46:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: "eggert@cs.ucla.edu" Cc: "76290@debbugs.gnu.org" <76290@debbugs.gnu.org> Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173972075921380 (code B ref 76290); Sun, 16 Feb 2025 15:46:01 +0000 Received: (at 76290) by debbugs.gnu.org; 16 Feb 2025 15:45:59 +0000 Received: from localhost ([127.0.0.1]:36426 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tjgqD-0005Yk-HP for submit@debbugs.gnu.org; Sun, 16 Feb 2025 10:45:59 -0500 Received: from mail-4319.protonmail.ch ([185.70.43.19]:38391) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tjcQF-0007d9-50 for 76290@debbugs.gnu.org; Sun, 16 Feb 2025 06:02:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739703764; x=1739962964; bh=a7yLhGgmDoRKTy7FJ1xyMxLySTcKbxKHe0N+wPx23Mg=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=C318z1WL06KMqsVMX9w5EoyLYYcQ/U9r6RoXdYK+R3GpwAh1K0v3tZm7AwME6O/96 5XhQHrBjJ9qZyD4yAQe39Au9GveUORRWlhSZokqPW9zf38KivGrYnBcpFlkpUkdBpa MEFRxryJcJ2nkMwZJUcsCn6fftT/yXSwAE14dHn+sDNFSeQWnWezTWsxS23seApmrm DLJqwzyA+H7Xv3argq7+C4EiqR2WUnbFJU/oUnQW1JiT0jfPO1TrG+UxBMmkXxg1B6 RagwALwQae2kbliKmW558O7secI/HbF1VGjenF8KmgFSSuvOLHpmyn83yUQmkg+Bsh u/ybMO363cV9A== Date: Sun, 16 Feb 2025 11:02:37 +0000 From: Rupert Gallagher Message-ID: In-Reply-To: References: Feedback-ID: 945109:user:proton X-Pm-Message-ID: 8c466c78682303bd2cebb3885a5901da75312085 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Mailman-Approved-At: Sun, 16 Feb 2025 10:45:55 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) My concern is best described as follows. ~ $ echo -e "CVE-2018-13787\nCVE-2019-16649\nCVE-2019-16650\nCVE-2020-15046= \nCVE-2018-13787" | sort -h CVE-2018-13787 CVE-2018-13787 CVE-2019-16649 CVE-2019-16650 CVE-2020-15046 ~ $ echo -e "CVE-2018-13787\nCVE-2019-16649\nCVE-2019-16650\nCVE-2020-15046= \nCVE-2018-13787" | sort -h -u CVE-2018-13787 The introduction of the unique operator (-u) returns a wrong answer when us= ed with the human sorting operator (-h). Note the problem does not occur when the human sorting operator is not used= . ~ $ echo -e "CVE-2018-13787\nCVE-2019-16649\nCVE-2019-16650\nCVE-2020-15046= \nCVE-2018-13787" | sort CVE-2018-13787 CVE-2018-13787 CVE-2019-16649 CVE-2019-16650 CVE-2020-15046 ~ $ echo -e "CVE-2018-13787\nCVE-2019-16649\nCVE-2019-16650\nCVE-2020-15046= \nCVE-2018-13787" | sort -u CVE-2018-13787 CVE-2019-16649 CVE-2019-16650 CVE-2020-15046 The example suggests the existence of a programming error between the outpu= t of -h and the input of -u. -------- Original Message -------- On 2/16/25 07:23, Paul Eggert wrote: > I don't see a bug there, just an infelicity. -h means 'sort' should look= for a number, and your data lines don't start with numbers. > =20 > Try 'sort --debug -h -u' to see more. > From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: "Philip Rowlands" Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Sun, 16 Feb 2025 17:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: "Paul Eggert" , "Rupert Gallagher" Cc: 76290@debbugs.gnu.org Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173972680321246 (code B ref 76290); Sun, 16 Feb 2025 17:27:02 +0000 Received: (at 76290) by debbugs.gnu.org; 16 Feb 2025 17:26:43 +0000 Received: from localhost ([127.0.0.1]:36813 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tjiPj-0005Wb-AV for submit@debbugs.gnu.org; Sun, 16 Feb 2025 12:26:43 -0500 Received: from fhigh-b3-smtp.messagingengine.com ([202.12.124.154]:40643) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tjiPf-0005Vu-U4 for 76290@debbugs.gnu.org; Sun, 16 Feb 2025 12:26:41 -0500 Received: from phl-compute-04.internal (phl-compute-04.phl.internal [10.202.2.44]) by mailfhigh.stl.internal (Postfix) with ESMTP id 6933C25400D3; Sun, 16 Feb 2025 12:26:33 -0500 (EST) Received: from phl-imap-08 ([10.202.2.84]) by phl-compute-04.internal (MEProxy); Sun, 16 Feb 2025 12:26:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dimebar.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm2; t=1739726793; x=1739813193; bh=+CEDpLPjoalcXLwVd4cD7da2gFwc4dCApfe0iFavYa4=; b= LbyoBe0qhvFshIBqVvRbxmBlIaj/mSNyZpoTTm5Q3sx3BzlSwDDNEhCsgipALRQb XSvD8A5qfat4vL8sV5cx6KlUhZQ4F+qzQ3FDK3imKuJusulEFVMcnxqWEd4GwMav d/II7iSnYX9htzodoyeakpwwKtbqt0i5AxTkI44NmEzZ2K5Ur3oYfIYy9Q+6MOpx o0v/+VcZSogIwoxCbdUN5tLdyndnQbpqMw5uWjYdBNsV8rTOrbzJeJngJxieC7j7 Lhd362Gm7wXzyzaDquI6tTFlUOOU0WNA8H7DcDqGZmtAaj+2I5BiqSrJB9sI0T95 tlike1fhIo/ATD7cTs0yNg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1739726793; x= 1739813193; bh=+CEDpLPjoalcXLwVd4cD7da2gFwc4dCApfe0iFavYa4=; b=f SvMaZ7easHxvLWGHur9Y536aS06NV9uYJIFQG9RHtmXBpXq7pBTKB3S+itZs0GSl 7Od7kwTz0hR4GeMNMiAc+w6Y1WvwvrjjCeYTnfe0vzyMy0snQW/au43CNcbqmai+ 1GcalEuJE9sQDl8Aspw3vI0vctPlp0HPb7ocwEoAtLets10G7ZeY2+EQh+LupRd7 CuYEsPfCxdso5Nq/AlLX9hy+FI3dptCboYQw5OD2igr3q/A/0frHyjRwidvRt80C l/heJGoLHJI1zVbaPjiUxishDIGfYUofvw1Hq4y33fxL+gTAb1sAvGDIoghck1cn QchkLPJsy/8UicD/qgdYg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdehiedtiecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpefoggffhffvvefkjghfufgtgfesthejredtredt tdenucfhrhhomhepfdfrhhhilhhiphcutfhofihlrghnughsfdcuoehphhhrodgtohhrvg huthhilhhsseguihhmvggsrghrrdgtohhmqeenucggtffrrghtthgvrhhnpeevteduvdej leetuddukeeigfetfeegveffudekudelvdekteegfedvudffffegueenucevlhhushhtvg hrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehphhhrodgtohhrvghuthhi lhhsseguihhmvggsrghrrdgtohhmpdhnsggprhgtphhtthhopeefpdhmohguvgepshhmth hpohhuthdprhgtphhtthhopegvghhgvghrthestghsrdhutghlrgdrvgguuhdprhgtphht thhopeejiedvledtseguvggssghughhsrdhgnhhurdhorhhgpdhrtghpthhtoheprhhugh grsehprhhothhonhhmrghilhdrtghomh X-ME-Proxy: Feedback-ID: i3ef94498:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id E1C3518A006B; Sun, 16 Feb 2025 12:26:32 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface MIME-Version: 1.0 Date: Sun, 16 Feb 2025 17:23:18 +0000 From: "Philip Rowlands" Message-Id: <7ecb96ea-c43e-4917-9824-d730f22358dd@app.fastmail.com> In-Reply-To: References: Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Sun, 16 Feb 2025, at 06:23, Paul Eggert wrote: > I don't see a bug there, just an infelicity. -h means 'sort' should look > for a number, and your data lines don't start with numbers. > > Try 'sort --debug -h -u' to see more. The --debug output here isn't as helpful as it could be; taking a simplified example $ echo -e 'CVE-222\nCVE-111\nCVE-222' | sort -h -u --debug sort: text ordering performed using simple byte comparison sort: note numbers use '.' as a decimal point in this locale CVE-222 ^ no match for key $ echo $'bbb\naaa' | sort -n -u --debug sort: text ordering performed using simple byte comparison sort: note numbers use '.' as a decimal point in this locale bbb ^ no match for key Due to the diligent work by maintainers, there are very few genuine bugs in sort, so we can assume --debug users need as much help as possible figuring out where the sort options have gone wrong. How could the "no match for key" output here be clearer? Could --uniq --debug show elided lines with an explanation, especially for entire lines which match nothing? Cheers, Phil From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Sun, 16 Feb 2025 22:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Rupert Gallagher Cc: "76290@debbugs.gnu.org" <76290@debbugs.gnu.org> Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173974458025936 (code B ref 76290); Sun, 16 Feb 2025 22:23:02 +0000 Received: (at 76290) by debbugs.gnu.org; 16 Feb 2025 22:23:00 +0000 Received: from localhost ([127.0.0.1]:38549 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tjn2R-0006kE-M0 for submit@debbugs.gnu.org; Sun, 16 Feb 2025 17:22:59 -0500 Received: from mail.cs.ucla.edu ([131.179.128.66]:39814) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tjn2N-0006jZ-NI for 76290@debbugs.gnu.org; Sun, 16 Feb 2025 17:22:57 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 792C43C00D403; Sun, 16 Feb 2025 14:22:49 -0800 (PST) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id ysf4w3TA0v5n; Sun, 16 Feb 2025 14:22:49 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 2ABE73C00D404; Sun, 16 Feb 2025 14:22:49 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 2ABE73C00D404 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1739744569; bh=xR/s3WZOPRGynIujy3s5E9D7xlpqivvOin/w08IUnhE=; h=Message-ID:Date:MIME-Version:To:From; b=JfJjhfHF8G/1c8DK9PtzAJOKfoMLBUvVIRAhkt4Ix+cAf+zWdw1E81/lYI5CVowxS 53p+xyvsQ/mD++CbNJdL7tXPZ23YT7/3MSHN/NVygFc5FXluzLYMME1/t8ARio88wy LqPkfLr0gxGnBuooN/2RumWHEHiNs0P3Y/XQdqcdjqG7rGzloPNTdUMIVaMWT75JJg +w9u4SbZ+dgkoswOT+hHZ0ZsWWyYxRi0ETJOPGHAGK9+TTYr9x3AqNab/6/QgOmXU1 DOFKWiAh0EzquFdRW7HrDtWSYshxBs+sec9CN29X8YI5jiUs/ocS00aSdNqjRI6CCP 73YElydorO1JA== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id hBuIJkxCCtQ7; Sun, 16 Feb 2025 14:22:49 -0800 (PST) Received: from [192.168.254.12] (unknown [47.147.225.25]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 0F9823C00D403; Sun, 16 Feb 2025 14:22:49 -0800 (PST) Message-ID: Date: Sun, 16 Feb 2025 14:22:48 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2025-02-16 03:02, Rupert Gallagher wrote: > The introduction of the unique operator (-u) returns a wrong answer when used with the human sorting operator (-h). The answer is "wrong" only in the sense that sort's documented and implemented behavior is not what you expect. To fix this mismatch between behavior and expectations, don't use -h. It makes sense to not use -h, -h is not intended for uses like that. From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Mon, 17 Feb 2025 23:32:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Rupert Gallagher Cc: "76290@debbugs.gnu.org" <76290@debbugs.gnu.org> Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173983508022427 (code B ref 76290); Mon, 17 Feb 2025 23:32:02 +0000 Received: (at 76290) by debbugs.gnu.org; 17 Feb 2025 23:31:20 +0000 Received: from localhost ([127.0.0.1]:51047 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkAa7-0005pZ-Kj for submit@debbugs.gnu.org; Mon, 17 Feb 2025 18:31:20 -0500 Received: from mail.cs.ucla.edu ([131.179.128.66]:38078) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkAa4-0005ou-S1 for 76290@debbugs.gnu.org; Mon, 17 Feb 2025 18:31:17 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id C08083C00FA86; Mon, 17 Feb 2025 15:31:10 -0800 (PST) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id 1Wh_E14ifAz5; Mon, 17 Feb 2025 15:31:10 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 6A2543C00FA88; Mon, 17 Feb 2025 15:31:10 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 6A2543C00FA88 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1739835070; bh=GzFzUoSwwkklbxD1bQ3f82LFHI/b1sn8HSuqC9Y2ApM=; h=Message-ID:Date:MIME-Version:To:From; b=P3eDH6WbDBlqrtohMXfJmdlLTArpOSnKnoZjg/IxRS0TvpvhaCMjQuPWZs64m5CLE +lDuJr3UAsSmSK2bAR5hEP76CVWksRozsmkaCMzzxp9SR2keZ78N4sMsqjReVEhk50 +7ljuPpzrlBikU3KnW6MACH2rW01JFLOPXuWzsUMcH94ijYs5fcYCIu85UvZI+lsBa tl2aQUdfcGnCYNH9DZlWVjgbt5jsSKBCumHgqbmtk1xBvKBT/xMlF3IJLWPaBDF6xN SO4zF7RW4q6b2lBuHBxe1ro6wKDmY6ITP6rTQco+O+NlYsRUi+0050fFRYM8qFq7A+ f1ys06G8TdlvQ== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id Pg8bOOi_tdgi; Mon, 17 Feb 2025 15:31:10 -0800 (PST) Received: from [192.168.254.12] (unknown [47.147.225.25]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 4CE813C00FA86; Mon, 17 Feb 2025 15:31:10 -0800 (PST) Message-ID: <8131f07a-7c42-43c8-97b7-e1a36f7223ad@cs.ucla.edu> Date: Mon, 17 Feb 2025 15:31:10 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2025-02-17 15:13, Rupert Gallagher wrote: > ~ $ echo -e "a1\na2" | sort > a1 > a2 > > ~ $ echo -e "a1\na2" | sort -h > a1 > a2 > > Since A = B, the result of -u must be the same on both sets, by logic. By that logic, since the output of these two commands: echo -e 'a1\na2' | sort echo -e 'a1\na2' | sort -n are the same, then the result of -u be the same on both sets. But this logic is wrong, in the sense that it disagrees with both longstanding practice and with the POSIX.1-2024 standard , which say that plain 'sort' uses the entire line as a key whereas 'sort -n' uses a leading integer prefix (which in this example is empty so the keys compare equal). I get it that 'sort' doesn't behave the way you expected. But that's a mismatch of expectations vs implementation, not a bug in the implementation. From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rupert Gallagher Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Tue, 18 Feb 2025 04:16:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: "eggert@cs.ucla.edu" Cc: "76290@debbugs.gnu.org" <76290@debbugs.gnu.org> Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.173985214919597 (code B ref 76290); Tue, 18 Feb 2025 04:16:05 +0000 Received: (at 76290) by debbugs.gnu.org; 18 Feb 2025 04:15:49 +0000 Received: from localhost ([127.0.0.1]:52732 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkF1P-00055m-E8 for submit@debbugs.gnu.org; Mon, 17 Feb 2025 23:15:49 -0500 Received: from mail-106104.protonmail.ch ([79.135.106.104]:49925) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkAJF-00049e-5d for 76290@debbugs.gnu.org; Mon, 17 Feb 2025 18:13:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739834025; x=1740093225; bh=GQ6dZi5lBGqCfL2Fk3p6WtcLgZnjZJW8trXBSny5L+w=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=SY0bEZ4UIo78MoUGAaJIy3ZNiq5LWfnsWOa5VW4aRE0BwTaRoJZN7Gpsmzh7w722s 7PIhj7F/Vi2C4Q/0Obmv1sIP0Np4QqUoOtaGOUWG65eE5VVhtZD7Mh9CzW08/24pNg qohj/S1m1am4fWAO8npfxch8wcTiuuBk0y+vNHTTvjPGoaZL36Cj4j38+Kly8BANF6 gcJMQ3YRiF+Hg/W54NoJAZ89yPJ/xOZndRkqODVLkj293C5+5jTwYwB/XQ1+H9039i W5l9rQyf3TbVJefkLu/FcFOGJAOnBWehlkTbGgHuCnGKmILmzp4fjZzPDBcZU00J2A r6XynbjTsLKkQ== Date: Mon, 17 Feb 2025 23:13:39 +0000 From: Rupert Gallagher Message-ID: In-Reply-To: References: Feedback-ID: 945109:user:proton X-Pm-Message-ID: abff94c9b320765cba1fee2d4be8430fa97450df MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Mailman-Approved-At: Mon, 17 Feb 2025 23:15:44 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) No, I expect the program to do exactly what the manual says.=20 -h, --human-numeric-sort compare human readable numbers (e.g., 2K 1G) Applying -h to the list in my example is expected to be semantically equiva= lent to not applying -h: A =3D { echo -e "a1\na2" | sort } B =3D { echo -e "a1\na2" | sort -h } ~ $ echo -e "a1\na2" | sort a1 a2 ~ $ echo -e "a1\na2" | sort -h a1 a2 Since A =3D B, the result of -u must be the same on both sets, by logic. Th= e program, however, has a mind of its own. ~ $ echo -e "a1\na2" | sort -u a1 a2 ~ $ echo -e "a1\na2" | sort -h -u a1 -------- Original Message -------- On 2/16/25 23:22, Paul Eggert wrote: > On 2025-02-16 03:02, Rupert Gallagher wrote: > > The introduction of the unique operator (-u) returns a wrong answer wh= en used with the human sorting operator (-h). > =20 > The answer is "wrong" only in the sense that sort's documented and > implemented behavior is not what you expect. > =20 > To fix this mismatch between behavior and expectations, don't use -h. It > makes sense to not use -h, -h is not intended for uses like that. > From unknown Sat Jun 21 03:23:34 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Rupert Gallagher Subject: bug#76290: closed (Re: bug#76290: "sort -u" vs "sort -h -u": possible bug) Message-ID: References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> X-Gnu-PR-Message: they-closed 76290 X-Gnu-PR-Package: coreutils Reply-To: 76290@debbugs.gnu.org Date: Tue, 18 Feb 2025 06:26:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1739859962-2805-1" This is a multi-part message in MIME format... ------------=_1739859962-2805-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #76290: "sort -u" vs "sort -h -u": possible bug which was filed against the coreutils package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 76290@debbugs.gnu.org. --=20 76290: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D76290 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1739859962-2805-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 76290-done) by debbugs.gnu.org; 18 Feb 2025 06:25:24 +0000 Received: from localhost ([127.0.0.1]:53639 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkH2q-0000go-Db for submit@debbugs.gnu.org; Tue, 18 Feb 2025 01:25:24 -0500 Received: from mail.cs.ucla.edu ([131.179.128.66]:41462) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkH2l-0000g3-7v for 76290-done@debbugs.gnu.org; Tue, 18 Feb 2025 01:25:22 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id CAEDE3C01409D; Mon, 17 Feb 2025 22:25:12 -0800 (PST) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id tQ3kMMV-1lo2; Mon, 17 Feb 2025 22:25:12 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 727653C0140A0; Mon, 17 Feb 2025 22:25:12 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu 727653C0140A0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1739859912; bh=UovjD6tHFDVSjrVVvqlu8F7wwtuXinJVk8xfp00CvKI=; h=Message-ID:Date:MIME-Version:To:From; b=F+9fZjw3yYbt2+IsaW7hpUQRITNmyzi9YQfkom8fc7z6aTDT7DvZdO9naun68kRbh cMut/KH0yqw1kHD6Wetz1QOYhLartSk2f+aOauiukI1kKbrPCfsuec3uv9NKGgDW3e L3VUiK1U7Lx3OM9PsdZEMWEliymU7fIQBgvciV6rnshlv2gcvKQDM0SjZL/U5hyYpa 13G/kqiVLr1wL6xITyDibAtosTFlVpQE2z9stdnhe8Olz9zDNaypW4lB6KcKoxEB4A nD29+iTCC4aynfx9jZ5/JdlPauTWyGzkeiep3Gf+Zfvfe8x8clw7u5dhKJuzkktfp3 4TJGAH+cIDBVA== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id FTXploqxXIWl; Mon, 17 Feb 2025 22:25:12 -0800 (PST) Received: from [192.168.254.12] (unknown [47.147.225.25]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id 514183C01409D; Mon, 17 Feb 2025 22:25:12 -0800 (PST) Message-ID: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Date: Mon, 17 Feb 2025 22:25:12 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#76290: "sort -u" vs "sort -h -u": possible bug To: Rupert Gallagher References: Content-Language: en-US From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76290-done Cc: 76290-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2025-02-17 15:13, Rupert Gallagher via GNU coreutils Bug Reports wrote: > I expect the program to do exactly what the manual says. Here's what the manual says about -u in : > Normally, output only the first of a sequence of lines that compare equal.... > > This option also disables the default last-resort comparison. > > The commands sort -u and sort | uniq are equivalent, but this equivalence does not extend to arbitrary sort options. For example, sort -n -u inspects only the value of the initial numeric string when checking for uniqueness, whereas sort -n | uniq inspects the entire line. This is the part of the manual that you're disagreeing with. The example in my previous email (an example that you did not reply to) is a demonstration of this part of the manual. I am taking the liberty of closing this bug report, as "sort" is behaving as documented here. ------------=_1739859962-2805-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 14 Feb 2025 17:00:04 +0000 Received: from localhost ([127.0.0.1]:51439 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tiz2m-0001nI-FO for submit@debbugs.gnu.org; Fri, 14 Feb 2025 12:00:04 -0500 Received: from lists.gnu.org ([2001:470:142::17]:58422) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tixs4-0006fJ-H0 for submit@debbugs.gnu.org; Fri, 14 Feb 2025 10:44:54 -0500 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 1tixry-0008PF-68 for bug-coreutils@gnu.org; Fri, 14 Feb 2025 10:44:46 -0500 Received: from mail-40141.protonmail.ch ([185.70.40.141]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tixrw-0003tv-Aw for bug-coreutils@gnu.org; Fri, 14 Feb 2025 10:44:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739547879; x=1739807079; bh=+4y3Uj6TIVd5mE+Jagsq85sYFUdjCw9MVodtdx7bI4k=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector: List-Unsubscribe:List-Unsubscribe-Post; b=vRNyBx6ErgHq/t9s9gdspvxvqmpaJXuzwXN3zQ03w6uDMamsZB8Ihwvxzx2Vlj6pp 5vEb3TDiTSdFNB5y/8Y68uJWuN41ysLwaUkZENi7Ky/vCiVijvetuTobco5w1NabRM cD+IIypQsuh+VVjU4yxdDj/DggGN1PGF50h2V+7IxBzK4XmQKM9zdu64zSBxQ7bqkW Jn1TwnGQd/K0DusTHKEdawjGc6554SJyllbg83rGTaErZ10/np6qlahEzKET4tDmIV 27mkqdX0/18w2+3qRu1VRqZYMCTBRvihfyEcpfyc9rUUs8FM5plJSN7jcV7e73O4S+ rsLexDyPr+WDw== Date: Fri, 14 Feb 2025 15:44:34 +0000 To: "bug-coreutils@gnu.org" From: Rupert Gallagher Subject: "sort -u" vs "sort -h -u": possible bug Message-ID: Feedback-ID: 945109:user:proton X-Pm-Message-ID: 01bfb0e1c1ed4a52f265069d7a283ca11d51766c MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU" Received-SPF: pass client-ip=185.70.40.141; envelope-from=ruga@protonmail.com; helo=mail-40141.protonmail.ch 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, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 14 Feb 2025 11:59:58 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: base64 PmVjaG8gLWUgIkNWRS0yMDE4LTEzNzg3XG5DVkUtMjAxOS0xNjY0OVxuQ1ZFLTIwMTktMTY2NTBc bkNWRS0yMDIwLTE1MDQ2XG5DVkUtMjAxOC0xMzc4NyIKQ1ZFLTIwMTgtMTM3ODcgPC0tLQpDVkUt MjAxOS0xNjY0OQpDVkUtMjAxOS0xNjY1MApDVkUtMjAyMC0xNTA0NkNWRS0yMDE4LTEzNzg3IDwt LS0KCj5lY2hvIC1l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nMtc2VyaWY7IGZvbnQtc2l6ZTogMTRweDsgY29sb3I6IHJnYigwLCAwLCAwKTsgYmFja2dyb3Vu ZC1jb2xvcjogcmdiKDI1NSwgMjU1LCAyNTUpOyI+PGJyPjwvZGl2PjxkaXYgY2xhc3M9InByb3Rv bm1haWxfc2lnbmF0dXJlX2Jsb2NrIHByb3Rvbm1haWxfc2lnbmF0dXJlX2Jsb2NrLWVtcHR5IiBz dHlsZT0iZm9udC1mYW1pbHk6IEFyaWFsLCBzYW5zLXNlcmlmOyBmb250LXNpemU6IDE0cHg7Ij4N CiAgICA8ZGl2IGNsYXNzPSJwcm90b25tYWlsX3NpZ25hdHVyZV9ibG9jay11c2VyIHByb3Rvbm1h aWxfc2lnbmF0dXJlX2Jsb2NrLWVtcHR5Ij4NCiAgICAgICAgDQogICAgICAgICAgICA8L2Rpdj4N CiAgICANCiAgICAgICAgICAgIDxkaXYgY2xhc3M9InByb3Rvbm1haWxfc2lnbmF0dXJlX2Jsb2Nr LXByb3RvbiBwcm90b25tYWlsX3NpZ25hdHVyZV9ibG9jay1lbXB0eSI+DQogICAgICAgIA0KICAg ICAgICAgICAgPC9kaXY+DQo8L2Rpdj4NCg== --b1=_bz3Fv7TLZ8LwCtblydmQ1sWZ30soAC7ZOFGMKIqU-- ------------=_1739859962-2805-1-- From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rupert Gallagher Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Tue, 18 Feb 2025 08:20:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: "eggert@cs.ucla.edu" Cc: "76290-done@debbugs.gnu.org" <76290-done@debbugs.gnu.org> Received: via spool by 76290-done@debbugs.gnu.org id=D76290.173986678312322 (code D ref 76290); Tue, 18 Feb 2025 08:20:02 +0000 Received: (at 76290-done) by debbugs.gnu.org; 18 Feb 2025 08:19:43 +0000 Received: from localhost ([127.0.0.1]:54341 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkIpS-0003Cg-Nv for submit@debbugs.gnu.org; Tue, 18 Feb 2025 03:19:43 -0500 Received: from mail-4319.protonmail.ch ([185.70.43.19]:62537) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkIpP-0003Bv-Uz for 76290-done@debbugs.gnu.org; Tue, 18 Feb 2025 03:19:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739866773; x=1740125973; bh=+JBrE1KnEiJc8g6AZxfV3pGiSqeR8yrE3GZdnYXyFok=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=gFJrbi5hqkZirMPUEEVvGd+PQtfZ5epo7TrjnI5d0LQiNe3GtmzKDtMRZt2h3sfGW PKsNmX12pk0mtfvlcefoIjfL4DWbkgHtsu/aBrHLKJ8E0/Oz5Pu9QUl8zQRkFyFiCm mnNBqqqNAI2abz52K4WOcsaPkg6JSRW2+YkC7cmSoEOCGbhzWG/vN59UF7GfWPysBq eq3Z+jpKOk5PDUkcLH6iFpxkYvlQjBUHxXOEWdknD0CqyAgFUeshIRQpBUkH62j6jC FGTblB78aTCV7Y0gt6gyqVAGaFfbTm46ql7q5LC4BuaRWoVsYsowc/RLi+ChWHQtDw 7LhMFF4BbgHXg== Date: Tue, 18 Feb 2025 08:19:25 +0000 From: Rupert Gallagher Message-ID: In-Reply-To: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Feedback-ID: 945109:user:proton X-Pm-Message-ID: 711bd6269beb91b9b8fa4ce71f67bac0e5f6d875 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) According to gnu sort -h -u and what you claim to be common practice, a lis= t of possibly redoundant strings, some beginning with a number, is reduced = to an ordered set of the numbered strings only. Since I expect the resulting ordered set to include the original elements, = I will then stop using gnu sort to avoid data loss. -------- Original Message -------- On 2/18/25 07:25, Paul Eggert wrote: > On 2025-02-17 15:13, Rupert Gallagher via GNU coreutils Bug Reports wrot= e: > > I expect the program to do exactly what the manual says. > =20 > Here's what the manual says about -u in > : > =20 > > Normally, output only the first of a sequence of lines that compar= e equal.... > > > > This option also disables the default last-resort comparison. > > > > The commands sort -u and sort | uniq are equivalent, but this equi= valence does not extend to arbitrary sort options. For example, sort -n -u = inspects only the value of the initial numeric string when checking for uni= queness, whereas sort -n | uniq inspects the entire line. > =20 > This is the part of the manual that you're disagreeing with. The example > in my previous email (an example that you did not reply to) is a > demonstration of this part of the manual. > =20 > I am taking the liberty of closing this bug report, as "sort" is > behaving as documented here. > =20 > From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rupert Gallagher Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Tue, 18 Feb 2025 18:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: "eggert@cs.ucla.edu" Cc: "76290-done@debbugs.gnu.org" <76290-done@debbugs.gnu.org> Received: via spool by 76290-done@debbugs.gnu.org id=D76290.173990437529497 (code D ref 76290); Tue, 18 Feb 2025 18:47:02 +0000 Received: (at 76290-done) by debbugs.gnu.org; 18 Feb 2025 18:46:15 +0000 Received: from localhost ([127.0.0.1]:33057 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkSbm-0007fa-IX for submit@debbugs.gnu.org; Tue, 18 Feb 2025 13:46:15 -0500 Received: from mail-43167.protonmail.ch ([185.70.43.167]:55847) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkSbi-0007ec-Kq for 76290-done@debbugs.gnu.org; Tue, 18 Feb 2025 13:46:11 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1739904363; x=1740163563; bh=qBohjTSlCyXSK9Re5S4x1+VWatvAlKQ0A0Ms7g+KomM=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=FYps5eRXhM0zZJJ383mYXucxO5SSPc1+0HVkZ2rdzYYEs7IQcyBNST6PWssgRt6hx AqiQoDvDDzJimVVQlERCV2M6cClT90XreFAyxvrP1oP0hwh2SXKECYC4UKcOUS/yJi QQpOMPi+Pcp5BD4UXZoAeVISzF9t+x+SYKlbQ5JfYF/zomz6mEYaNgDKT6pMuP/T1Y /IGUZ4akDZo3io/QgV3hjcyVM76kr3NKl9/QIwamAuGkVBe7jKyOMnZPANSkUpLE8i zm1EN2I9BgG5hHher4tHeAQrABhuA9d2xd3A0xaFrbIKvT6ONimE/WX2sHlNJ89nMu VwoMAWCh4oNgA== Date: Tue, 18 Feb 2025 18:45:57 +0000 From: Rupert Gallagher Message-ID: In-Reply-To: References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Feedback-ID: 945109:user:proton X-Pm-Message-ID: c850661cc1fa39b9153d08142a17d5a9cd002d19 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Dictionary sort corresponds to the intended behaviour. > echo -e "abc\n123\n456\nCVE-2011-234\nAbc\ndef\nCVE-2024-123" | sort --de= bug -dfu 123 ___ 456 ___ abc ___ CVE-2011-234 ____________ CVE-2024-123 ____________ def ___ By comparison, human (-h) and numeric (-n) sort cause data loss: > echo -e "abc\n123\n456\nCVE-2011-234\nAbc\ndef\nCVE-2024-123" | sort --de= bug -hu sort: note numbers use =E2=80=98.=E2=80=99 as a decimal point in this local= e abc ^ no match for key 123 ___ 456 ___ If I were the author of gnu sort, I would delete the -h and -n options. From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Bernhard Voelker Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Wed, 19 Feb 2025 17:16:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Rupert Gallagher , "eggert@cs.ucla.edu" Cc: "76290-done@debbugs.gnu.org" <76290-done@debbugs.gnu.org> Received: via spool by 76290-done@debbugs.gnu.org id=D76290.173998530819666 (code D ref 76290); Wed, 19 Feb 2025 17:16:02 +0000 Received: (at 76290-done) by debbugs.gnu.org; 19 Feb 2025 17:15:08 +0000 Received: from localhost ([127.0.0.1]:50501 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tknf9-00056s-AQ for submit@debbugs.gnu.org; Wed, 19 Feb 2025 12:15:07 -0500 Received: from mout.kundenserver.de ([212.227.126.135]:41121) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tknf5-000530-H7 for 76290-done@debbugs.gnu.org; Wed, 19 Feb 2025 12:15:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bernhard-voelker.de; s=s1-ionos; t=1739985296; x=1740590096; i=mail@bernhard-voelker.de; bh=DuFAr0agHFXATxBe7YN6bTyllJ/Afrck1ACxE1cLJcw=; h=X-UI-Sender-Class:Message-ID:Date:MIME-Version:Subject:To:Cc: References:From:In-Reply-To:Content-Type: Content-Transfer-Encoding:cc:content-transfer-encoding: content-type:date:from:message-id:mime-version:reply-to:subject: to; b=fe5i3rbUONe03oNXwqychjuwFYPKLySQYSoF4DIBETj6VuM4pM3aQRxBDgsR7HvV FMmcqvPUiLfvOPxj6f/Wy7y/72JNiK+WFDPKmeT4zDqPxDucsOH/8HOAwkliyGWLf mAVqi+h1eVWBJ20Rx4Ua1lwiCILRsDfzYPkiUVa7E00ZVoGyOGmqbfDUvo5eGZeHh /K3o9vnETJsFfpdaFkV4vQNhQCvC7f5LqJMEI6B3ktfMVetBhD1jVcVuSBJ6/jovE 2Q1pj/TFu4fMUevEORP9R6dHgqQiOMYi5ldpmsV92tbd68rfkK6NwthQ/obDwiDhD 5fJ15zKLABNjeFxmtQ== X-UI-Sender-Class: 55c96926-9e95-11ee-ae09-1f7a4046a0f6 Received: from [10.0.2.15] ([81.24.19.74]) by mrelayeu.kundenserver.de (mreue009 [213.165.67.97]) with ESMTPSA (Nemesis) id 1MbRXd-1tEDnd1yRN-00ZeDI; Wed, 19 Feb 2025 18:14:56 +0100 Message-ID: Date: Wed, 19 Feb 2025 18:14:13 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Content-Language: en-US From: Bernhard Voelker In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:7VEhVtFqRokyDYwAd0cjrxMMoNV+0QtFEZzz0zNddMsHtREHgOF ymygJrNpXAVUd4pMtElHBCBw9Pns+8dSFCNIWtwaivBT/uNBvx9hwoN2PaQzGKMAX01hgE1 uW1+XzDuATZOL8ibJArXp5YJAvZfTQfFUOtcgLSRVwU3ilNYtBy1YGToeAPispFZVaLIWhO HW8PWN52DRj6kjpvREWYA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:2UG+4ueW4tM=;sBQn3zss8JnpeJGXr7Ca1ZCb16f RV00IGIjLEeEiy9K1dpu4nWqahmU+KaRS8bzVy/lCGukR+4Q9SE3EoECYraSZACjbnjGCJZGp UJTt3plMXo+WA9KUfWWShvhSkbQAYh47D1v+2R152Ax6BtfuOAdPRKZF7Pk4kEIh4iwu5TLDW CX/WgthXRaE6nyfhYWPea1AHQwdNJF13ElDElfkMncLe6iLfWjtoW2as2t8KEiypeQsLfkIuB NGMxjJmJwEaAMrbwJFDYWDKoheUcXQehSxkSmqdj9neH1qppXrgFatLJLvnv4Qd2Q0/cj41eA 33P2zgv26NhPEv3KtMpI4Ju7K2NfmlM5OTXUEfKnec9ZZxrFbD1P5g7xKylfbAb8n0+BoVukV Zadeb4KyeaKWIK2Cr0/wUMSWc8LmB00MrIatLzUH5uCDztpmObu/3TRiaY+yfja4MrcZFnkpg F2GFMcIfJfJHqGKafMVWgYa+IIqw44jbx0s9jnTi/y2YWA9Tbg+4iIcSeCuiJbO03xyzdWVH/ mFYKREDbwVEiRy++W1Zq6UJqRob+BgfuS7wUrFFuUf/yRFiHzTkZOM0nXsWVd01Xj4N2+kSBF cCfyTyD+eG8ene3oomALJ3LNLqxC0uCiZtQTMgfV9AYqfU/UeYPTvSChp6rT2kdG5w8NZB3Tl /3cb88YG1QxqpxUeMMnt39lSEEJ0Bws+IT8/RZuXdm2V77coogMVHzqyZYYHT4dyHn+pGhwyv h/MlPacXcdHXEGVY9Gcdt+rEJwoKc9hVeewxbyafvEF3GjHM0smjS2OhQH8jhbL2Uh5leyGwk I4hTWwBxalTb4ZJsx4eM431x0Vm0Eypm+DGgxFgDIE6T9uqxqhkFxbvTa1UcGuAgI3rhkOfM9 V5xbDmRFtnrQWKHd5Qtp8U4F7YXLWsOMHXv8YZfvGjq9PucH25aFKLHA2uPt4nybHOTMnFXBt yuJm0+qHtcp0EaYlGGs4GW/YuBYQzaQs7TvKPBPxVwJW3HvNafF7RY3PAs5tlpxcTRoJZ3yax TYDP6GmGm4IrmP6+xtGgFBjk2/+E221R3tgaFirLnmQ+ojHZO0n6ROKUBmQN5DKU5yqg8KI+R bA2Dg3Xl4gD9kEwbN4QzcS4q7k5hahcbcO2KKoozppi1jppuLunVexuGzXdWLLQbuMRiDjyDU P/cTo6m/ojlLGpQJ8WPqO3IAtTIQVSSbW3OSAbDXOBhsDhPHRh1V5lujiyssOK3C3H+r44teB tEUwuHOSuG7MHzlKnUIbWqKrBz096+tkXEa4a2WwRmiSBeFypulPwirIAvhBfMKHh9Zhz0rH0 k/bZCaiPb+pJzyx3oag9fcJ4qq4V6Cv+VzHuog+sNRRwwzNH6Z44ljrX6KBHlm2pMk6tTE6QD RGggVda5hWU4kKBg== X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2/18/25 7:45 PM, Rupert Gallagher via GNU coreutils Bug Reports wrote: > By comparison, human (-h) and numeric (-n) sort cause data loss: not really. That's the difference between a) "I have a list containing numbers; I merely care about numbers and want to get a unique, sorted list of them." ('sort -h -u') and b) "I have a list containing numbers; I want to have it sorted by numbers, and then throw away duplicates." ('sort -h | uniq') The point is: in case a), the numerical value of each non-number entry is Zero. Consider the following: $ printf "%s\n" 0 1 X-1 Ab2 3 ma | LC_ALL=C sort -nu 0 1 3 Here, the entries 0, "X-1", "Ab2" and "ma" all have the numerical value 0. That's why the first Zero is output. Now let's remove the literal/numerical 0 from the input: $ printf "%s\n" 1 X-1 Ab2 3 ma | LC_ALL=C sort -nu X-1 1 3 Now, the first entry which represents numerically 0 is "X-1". Now even let's put the 0 back into the input, but at the end: $ printf "%s\n" 1 X-1 Ab2 3 ma 0 | LC_ALL=C sort -nu X-1 1 3 Still, sort(1) outputs the first entry which has a numerical value of Zero: "X-1". Have a nice day, Berny From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Rainer Canavan Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Wed, 19 Feb 2025 19:16:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 76290@debbugs.gnu.org X-Debbugs-Original-To: bug-coreutils@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.17399925338057 (code B ref -1); Wed, 19 Feb 2025 19:16:01 +0000 Received: (at submit) by debbugs.gnu.org; 19 Feb 2025 19:15:33 +0000 Received: from localhost ([127.0.0.1]:51895 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkpXh-00025s-Fs for submit@debbugs.gnu.org; Wed, 19 Feb 2025 14:15:33 -0500 Received: from lists.gnu.org ([2001:470:142::17]:59434) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkpXd-00024q-IM for submit@debbugs.gnu.org; Wed, 19 Feb 2025 14:15:30 -0500 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 1tkpXY-0002TK-8S for bug-coreutils@gnu.org; Wed, 19 Feb 2025 14:15:24 -0500 Received: from mail.canavan.de ([78.35.14.45] helo=whaitiri.canavan.de) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tkpXW-0001Gc-7w for bug-coreutils@gnu.org; Wed, 19 Feb 2025 14:15:24 -0500 Received: from [10.33.33.33] (xdsl-78-35-54-112.nc.de [78.35.54.112]) by whaitiri.canavan.de (Postfix) with ESMTPSA id 02A1B139847 for ; Wed, 19 Feb 2025 20:15:15 +0100 (CET) Message-ID: Date: Wed, 19 Feb 2025 20:15:17 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Content-Language: en-US From: Rainer Canavan In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=78.35.14.45; envelope-from=coreutils@canavan.de; helo=whaitiri.canavan.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) On 19.02.25 18:14, Bernhard Voelker wrote: On 2/18/25 7:45 PM, Rupert Gallagher via GNU coreutils Bug Reports wrote: > By comparison, human (-h) and numeric (-n) sort cause data loss: not really.  That's the difference between a)   "I have a list containing numbers; I merely care about numbers and want to get a unique, sorted list of them."   ('sort -h -u') and b)   "I have a list containing numbers; I want to have it sorted by numbers, and then throw away duplicates."   ('sort -h | uniq') The point is: in case a), the numerical value of each non-number entry is Zero. I have no issue with the way 'sort -u' is currently working, but the man page isn't clear at all about the fact that 'sort -h -u' and 'sort -h | uniq' behave differently. Specifically, the explanation for -u -u, --unique              with -c, check for strict ordering; without -c, output only the first of an equal run does not provide any explanation what 'equal' or 'run' may mean. Maybe add something like "where equality is assessed only based on the keys and rules used to sort the output". Rainer From unknown Sat Jun 21 03:23:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#76290: "sort -u" vs "sort -h -u": possible bug Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Wed, 19 Feb 2025 21:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76290 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Rainer Canavan Cc: 76290@debbugs.gnu.org Received: via spool by 76290-submit@debbugs.gnu.org id=B76290.174000008622859 (code B ref 76290); Wed, 19 Feb 2025 21:22:02 +0000 Received: (at 76290) by debbugs.gnu.org; 19 Feb 2025 21:21:26 +0000 Received: from localhost ([127.0.0.1]:53230 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkrVV-0005wT-5Q for submit@debbugs.gnu.org; Wed, 19 Feb 2025 16:21:25 -0500 Received: from mail.cs.ucla.edu ([131.179.128.66]:33136) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkrVS-0005vS-6A for 76290@debbugs.gnu.org; Wed, 19 Feb 2025 16:21:23 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id 62D363C00E401; Wed, 19 Feb 2025 13:21:15 -0800 (PST) Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10032) with ESMTP id nUTSpp6_mcxO; Wed, 19 Feb 2025 13:21:14 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by mail.cs.ucla.edu (Postfix) with ESMTP id D2AA83C00E404; Wed, 19 Feb 2025 13:21:14 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.10.3 mail.cs.ucla.edu D2AA83C00E404 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cs.ucla.edu; s=9D0B346E-2AEB-11ED-9476-E14B719DCE6C; t=1740000074; bh=D4GXI6thluJwWhmlXxEK68KVmeyKJvVLnIY3TQh1PXw=; h=Message-ID:Date:MIME-Version:To:From; b=LslQwUG/Xq9+T0YeyCwX5MbL1DjuMZELUQ+maAY1xgPfFLh9mGJlKOjmDdoUsmDXu z1NiNyeTtvVkY2ePWHjlLdlLNN2Rr4Eog5mhnAWBeFr24tWgtk6YxRMJRVfg2iqY11 NdAOXtsHxIykmcnH1kM8oV3SwG23e2Fx0o+8bU1qPznjkf2YMlOuM2708V8dsO/KV5 OZy3ts/kv3fa/qmxCNt+P0RMwqWM7bdtN6XM6wvJ3JB3f7Os5N955GepuZrTEr0RQG Fb2c2VlcvwCndSImMmQ5+LGBWuWMpG1b7c3hO65NB94Hu39gshWfEunU7l7BmVsfgt OvgCTN7pQ6zGg== X-Virus-Scanned: amavis at mail.cs.ucla.edu Received: from mail.cs.ucla.edu ([127.0.0.1]) by localhost (mail.cs.ucla.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id KMPMA6b0ZkEw; Wed, 19 Feb 2025 13:21:14 -0800 (PST) Received: from [131.179.64.200] (Penguin.CS.UCLA.EDU [131.179.64.200]) by mail.cs.ucla.edu (Postfix) with ESMTPSA id B8F373C00E401; Wed, 19 Feb 2025 13:21:14 -0800 (PST) Content-Type: multipart/mixed; boundary="------------I1KrHWcgU9jqXKS2Fnv0B4w9" Message-ID: <8777eade-24d5-423a-9cb4-951c68d2ba7f@cs.ucla.edu> Date: Wed, 19 Feb 2025 13:21:14 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird References: <2e3f214d-7a81-4bd2-ac7c-86943be3c89c@cs.ucla.edu> Content-Language: en-US From: Paul Eggert Autocrypt: addr=eggert@cs.ucla.edu; keydata= xsFNBEyAcmQBEADAAyH2xoTu7ppG5D3a8FMZEon74dCvc4+q1XA2J2tBy2pwaTqfhpxxdGA9 Jj50UJ3PD4bSUEgN8tLZ0san47l5XTAFLi2456ciSl5m8sKaHlGdt9XmAAtmXqeZVIYX/UFS 96fDzf4xhEmm/y7LbYEPQdUdxu47xA5KhTYp5bltF3WYDz1Ygd7gx07Auwp7iw7eNvnoDTAl KAl8KYDZzbDNCQGEbpY3efZIvPdeI+FWQN4W+kghy+P6au6PrIIhYraeua7XDdb2LS1en3Ss mE3QjqfRqI/A2ue8JMwsvXe/WK38Ezs6x74iTaqI3AFH6ilAhDqpMnd/msSESNFt76DiO1ZK QMr9amVPknjfPmJISqdhgB1DlEdw34sROf6V8mZw0xfqT6PKE46LcFefzs0kbg4GORf8vjG2 Sf1tk5eU8MBiyN/bZ03bKNjNYMpODDQQwuP84kYLkX2wBxxMAhBxwbDVZudzxDZJ1C2VXujC OJVxq2kljBM9ETYuUGqd75AW2LXrLw6+MuIsHFAYAgRr7+KcwDgBAfwhPBYX34nSSiHlmLC+ KaHLeCLF5ZI2vKm3HEeCTtlOg7xZEONgwzL+fdKo+D6SoC8RRxJKs8a3sVfI4t6CnrQzvJbB n6gxdgCu5i29J1QCYrCYvql2UyFPAK+do99/1jOXT4m2836j1wARAQABzSBQYXVsIEVnZ2Vy dCA8ZWdnZXJ0QGNzLnVjbGEuZWR1PsLBlQQTAQgAPwIbAwYLCQgHAwIGFQgCCQoLBBYCAwEC HgECF4AWIQR+N5Kp2Kz31jO8FYjt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DV Q/tNcwVWmOS+gdv9Wk6tdGeM+Ee+Qs6YG05jcSoajzF0TL07ajLcayRq2j1Os2CtQ8qu Organization: UCLA Computer Science Department In-Reply-To: X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) This is a multi-part message in MIME format. --------------I1KrHWcgU9jqXKS2Fnv0B4w9 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 2/19/25 11:15, Rainer Canavan wrote: > -u, --unique > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0with -c, check for strict ordering; without -c, output=20 > only the first of an equal run >=20 > does not provide any explanation what 'equal' or 'run' may mean. Maybe=20 > add something like "where equality is assessed only based on the keys=20 > and rules used to sort the output". Thanks for the suggestion. Although that's a bit long for "sort --help",=20 I take the point that equality comparison could be mentioned and=20 installed the attached to try to make things clearer without adding so=20 much length. --------------I1KrHWcgU9jqXKS2Fnv0B4w9 Content-Type: text/x-patch; charset=UTF-8; name="0001-sort-improve-u-brief-doc.patch" Content-Disposition: attachment; filename="0001-sort-improve-u-brief-doc.patch" Content-Transfer-Encoding: base64 RnJvbSAzMzI0MzQ0ODIwYjZmMzU2NmVkNjU5YmVmZTliYmZjZjJiMWYxMjk4IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 PgpEYXRlOiBXZWQsIDE5IEZlYiAyMDI1IDEzOjE3OjQ4IC0wODAwClN1YmplY3Q6IFtQQVRD SF0gc29ydDogaW1wcm92ZSAtdSBicmllZiBkb2MKCiogc3JjL3NvcnQuYyAodX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gICBmcHV0cyAoXygiXAogICAteiwgLS16ZXJvLXRlcm1pbmF0ZWQgICAgIGxp bmUgZGVsaW1pdGVyIGlzIE5VTCwgbm90IG5ld2xpbmVcblwKLS0gCjIuNDguMQoK --------------I1KrHWcgU9jqXKS2Fnv0B4w9--