Subject: bug#18273: closed (Re: bug#18273: sort seems to misbehave if both -u and -n or -k are used)

From: "Lennart Sorensen" <[email-masked]>
Date: Fri, 15 Aug 2014 16:22:07 -0400

On Fri, Aug 15, 2014 at 07:50:04PM +0000, GNU bug Tracking System wrote:
> Your bug report
> 
> #18273: sort seems to misbehave if both -u and -n or -k are used
> 
> 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 [email-masked].
> 
> -- 
> 18273: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=18273
> GNU Bug Tracking System
> Contact [email-masked] with problems

> From: Eric Blake <[email-masked]>
> To: Lennart Sorensen <[email-masked]>,
>  [email-masked]
> Subject: Re: bug#18273: sort seems to misbehave if both -u and -n or -k are
>  used
> 
> tag 18273 notabug
> thanks
> 
> On 08/15/2014 01:30 PM, Lennart Sorensen wrote:
> > Here is the case that has me thinking there is a bug (it sure doesn't
> > make sense as valid behaviour).
> 
> Thanks for the report.  However, the behavior you have demonstrated is
> required by POSIX, and is therefore not a bug.  The --debug option can
> be used to see what is really happening.

OK I accept that it is correct behaviour.

The documentation on the other hand is awful in that case.  I went and
checked the documentation to try and make sense of what it was doing
before sending the report, and there was nothing there that gave any
hint that this was expected behaviour.

Why does it have a blob talking about which options implicitly enable -s,
rather than mention that in the documentation for the options that do it.

Why does it not mention for -n that anything that isn't a number is
ignored and treated as if it didn't exist when it comes to deciding
things like uniqueness?  Are people expected to go read the posix
standard instead?

-- 
Len Sorensen