Debian Bug report logs - #648264
rlwrap: tab completion skips words that are prefixes of other words

version graph

Package: rlwrap; Maintainer for rlwrap is Thomas Ward <teward@ubuntu.com>; Source for rlwrap is src:rlwrap (PTS, buildd, popcon).

Reported by: Mike Miller <mtmiller@debian.org>

Date: Thu, 10 Nov 2011 02:51:01 UTC

Severity: wishlist

Tags: upstream

Found in version rlwrap/0.37-1

Fixed in version rlwrap/0.41-1

Done: Mike Miller <mtmiller@debian.org>

Bug is archived. No further changes may be made.

Forwarded to hanslub42@gmail.com

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Francois Marier <francois@debian.org>:
Bug#648264; Package rlwrap. (Thu, 10 Nov 2011 02:51:04 GMT) (full text, mbox, link).


Acknowledgement sent to Mike Miller <mtmiller@ieee.org>:
New Bug report received and forwarded. Copy sent to Francois Marier <francois@debian.org>. (Thu, 10 Nov 2011 02:51:04 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Mike Miller <mtmiller@ieee.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: rlwrap: tab completion skips words that are prefixes of other words
Date: Wed, 09 Nov 2011 21:48:33 -0500
Package: rlwrap
Version: 0.37-1
Severity: normal
Tags: upstream

When the word completion list contains two valid words, one of which is a
prefix of another, typing <tab> completes the longer word, skipping over the
shorter.

Discovered while following the instructions at [0] for configuring rlwrap with
clojure.  The completion list contains "vec", "vector", and "vector?" for
example.  Entering "ve<tab><tab><tab>" yields "vector?" as the only completion,
consuming the other valid word completions.

A simpler artificial example:
$ cat words.txt
i
id
ide
idea
ideas
$ rlwrap -f words.txt cat

Repeatedly pressing <tab> will add one letter at a time until "ideas" is
produced, same for the next word, and so on.

Desired behavior with user input of "id<tab><tab><tab><tab>..." is to display
"id ide idea ideas" all as possible completions.

[0] http://en.wikibooks.org/wiki/Clojure_Programming/Getting_Started



-- System Information:
Debian Release: 6.0.3
  APT prefers proposed-updates
  APT policy: (500, 'proposed-updates'), (500, 'stable'), (101, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages rlwrap depends on:
ii  libc6                     2.11.2-10      Embedded GNU C Library: Shared lib
ii  libncurses5               5.7+20100313-5 shared libraries for terminal hand
ii  libreadline6              6.1-3          GNU readline and history libraries

rlwrap recommends no packages.

rlwrap suggests no packages.

-- no debconf information




Reply sent to Francois Marier <francois@debian.org>:
You have marked Bug as forwarded. (Thu, 10 Nov 2011 04:15:04 GMT) (full text, mbox, link).


Message #8 received at 648264-forwarded@bugs.debian.org (full text, mbox, reply):

From: Francois Marier <francois@debian.org>
To: hanslub42@gmail.com
Cc: 648264-forwarded@bugs.debian.org
Subject: rlwrap: tab completion skips words that are prefixes of other words
Date: Thu, 10 Nov 2011 17:05:35 +1300
Hi Hans,

For your information, Mike Miller has filed the bug below on the Debian
tracker:

  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648264

Cheers,
Francois

----- Forwarded message from Mike Miller <mtmiller@ieee.org> -----

When the word completion list contains two valid words, one of which is a
prefix of another, typing <tab> completes the longer word, skipping over the
shorter.

Discovered while following the instructions at [0] for configuring rlwrap with
clojure.  The completion list contains "vec", "vector", and "vector?" for
example.  Entering "ve<tab><tab><tab>" yields "vector?" as the only completion,
consuming the other valid word completions.

A simpler artificial example:
$ cat words.txt
i
id
ide
idea
ideas
$ rlwrap -f words.txt cat

Repeatedly pressing <tab> will add one letter at a time until "ideas" is
produced, same for the next word, and so on.

Desired behavior with user input of "id<tab><tab><tab><tab>..." is to display
"id ide idea ideas" all as possible completions.

[0] http://en.wikibooks.org/wiki/Clojure_Programming/Getting_Started

----- End forwarded message -----




Information forwarded to debian-bugs-dist@lists.debian.org, Francois Marier <francois@debian.org>:
Bug#648264; Package rlwrap. (Thu, 10 Nov 2011 09:39:17 GMT) (full text, mbox, link).


Acknowledgement sent to Hans Lub <hanslub42@gmail.com>:
Extra info received and forwarded to list. Copy sent to Francois Marier <francois@debian.org>. (Thu, 10 Nov 2011 09:39:22 GMT) (full text, mbox, link).


Message #13 received at 648264@bugs.debian.org (full text, mbox, reply):

From: Hans Lub <hanslub42@gmail.com>
To: Francois Marier <francois@debian.org>
Cc: mtmiller@ieee.org
Subject: Re: rlwrap: tab completion skips words that are prefixes of other words
Date: Thu, 10 Nov 2011 09:50:56 +0100
Hello François
[cc Mike]

> Desired behavior with user input of "id<tab><tab><tab><tab>..." is to display
> "id ide idea ideas" all as possible completions.

That is certainly not the desired or expected behaviour with readline!
Using your words.txt (the one with 'ideas' and all of its prefixes):

[hlub@karpaten] ~ > rlwrap -f words.txt cat
i<TAB>
id     ide    idea   ideas
id<TAB>
ide    idea   ideas
ide<TAB>
idea   ideas
ideas (pressing TAB now will only add a space, as there are no more completions)

in the example above, i<TAB><TAB><TAB> is entered by me, the rest is
displayed by readine. For clarity, I have 'set show-all-if-ambiguous
On' in my .inputrc, but this doesn't change readline's completion
behaviour.

If I want "i", I press "i". rlwrap prints "i" and I accept it with <ENTER>"
If I want "id", I press "i<TAB>". rlwrap prints "id" and I accept it
with "<ENTER"
If I want "ide", I press "i<TAB><TAB>". rlwrap prints "ide" etc.

So, indeed, "i<TAB><TAB><TAB>" yields "ideas" as the only possible
completion - as it should!

regards

Hans






2011/11/10 Francois Marier <francois@debian.org>
>
> Hi Hans,
>
> For your information, Mike Miller has filed the bug below on the Debian
> tracker:
>
>  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648264
>
> Cheers,
> Francois
>
> ----- Forwarded message from Mike Miller <mtmiller@ieee.org> -----
>
> When the word completion list contains two valid words, one of which is a
> prefix of another, typing <tab> completes the longer word, skipping over the
> shorter.
>
> Discovered while following the instructions at [0] for configuring rlwrap with
> clojure.  The completion list contains "vec", "vector", and "vector?" for
> example.  Entering "ve<tab><tab><tab>" yields "vector?" as the only completion,
> consuming the other valid word completions.
>
> A simpler artificial example:
> $ cat words.txt
> i
> id
> ide
> idea
> ideas
> $ rlwrap -f words.txt cat
>
> Repeatedly pressing <tab> will add one letter at a time until "ideas" is
> produced, same for the next word, and so on.
>

>
> [0] http://en.wikibooks.org/wiki/Clojure_Programming/Getting_Started
>
> ----- End forwarded message -----



--
Hans Lub                                   tel/fax +31 (0)30 2899249
Dolomieten 74 3524 VH Utrecht (Nederland)            hanslub42@gmail.com





Information forwarded to debian-bugs-dist@lists.debian.org, Francois Marier <francois@debian.org>:
Bug#648264; Package rlwrap. (Fri, 11 Nov 2011 13:21:08 GMT) (full text, mbox, link).


Acknowledgement sent to Mike Miller <mtmiller@ieee.org>:
Extra info received and forwarded to list. Copy sent to Francois Marier <francois@debian.org>. (Fri, 11 Nov 2011 13:21:13 GMT) (full text, mbox, link).


Message #18 received at 648264@bugs.debian.org (full text, mbox, reply):

From: Mike Miller <mtmiller@ieee.org>
To: Hans Lub <hanslub42@gmail.com>
Cc: 648264@bugs.debian.org
Subject: Re: rlwrap: tab completion skips words that are prefixes of other words
Date: Fri, 11 Nov 2011 08:20:18 -0500
On Fri, Nov 11, 2011 at 4:12 AM, Hans Lub <hanslub42@gmail.com> wrote:
> Yes, I see your point. Thanks for pointing it out!
>
> bash, python, ... say: press Enter to accept, press <TAB> for all completions
> rlwrap says: press Enter to accept, press <TAB> for all *remaining* completions
>
> I find rlwrap more helpful, but expectations and muscle memory are to
> be reckoned with, so I will change its behaviour.
>
> A new rlwrap release (with lots of changes) is pending, and I don't
> think this bug warrants an interim bug-fix release, (though some of
> the other bugs do) This will probably have to wait until the 0.38
> version, sorry!

Hi Hans, thanks again for hearing me out, and for clarifying the
difference.  Let's call it a feature request instead of a bug.  Maybe
add an option to preserve the current, what I would call "aggressive
completion", behavior?

CCing to debian bts for the record, downgrading to wishlist, bug will
be fixed in next upstream release.

-- 
mike :: mtmiller at ieee dot org




Severity set to 'wishlist' from 'normal' Request was from Mike Miller <mtmiller@ieee.org> to control@bugs.debian.org. (Fri, 11 Nov 2011 13:24:03 GMT) (full text, mbox, link).


Changed Bug submitter to 'Mike Miller <mtmiller@debian.org>' from 'Mike Miller <mtmiller@ieee.org>' Request was from Mike Miller <mtmiller@debian.org> to control@bugs.debian.org. (Thu, 12 Dec 2013 14:12:05 GMT) (full text, mbox, link).


Reply sent to Mike Miller <mtmiller@debian.org>:
You have taken responsibility. (Fri, 12 Sep 2014 06:06:07 GMT) (full text, mbox, link).


Notification sent to Mike Miller <mtmiller@debian.org>:
Bug acknowledged by developer. (Fri, 12 Sep 2014 06:06:08 GMT) (full text, mbox, link).


Message #27 received at 648264-close@bugs.debian.org (full text, mbox, reply):

From: Mike Miller <mtmiller@debian.org>
To: 648264-close@bugs.debian.org
Subject: Bug#648264: fixed in rlwrap 0.41-1
Date: Fri, 12 Sep 2014 06:03:40 +0000
Source: rlwrap
Source-Version: 0.41-1

We believe that the bug you reported is fixed in the latest version of
rlwrap, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 648264@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Mike Miller <mtmiller@debian.org> (supplier of updated rlwrap package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Fri, 12 Sep 2014 01:13:54 -0400
Source: rlwrap
Binary: rlwrap
Architecture: source
Version: 0.41-1
Distribution: unstable
Urgency: medium
Maintainer: Mike Miller <mtmiller@debian.org>
Changed-By: Mike Miller <mtmiller@debian.org>
Description:
 rlwrap     - readline feature command line wrapper
Closes: 648264
Changes:
 rlwrap (0.41-1) unstable; urgency=medium
 .
   * New upstream version.
   * pselect-timeout-optimized-away.patch: Drop, applied upstream.
   * tab-completion-prefix.patch: Allow input text to be its own valid
     completion. (Closes: #648264)
   * Use dh-autoreconf to regenerate the build system, drop autotools-dev.
   * Add Depends on ${perl:Depends} substvar.
   * Run wrap-and-sort on debian/control.
Checksums-Sha1:
 e7be1386a35dc1ef42ecadd838408a76dd647738 1866 rlwrap_0.41-1.dsc
 9fbc6d977255a6081360230917a293b6fd9c5fbe 259472 rlwrap_0.41.orig.tar.gz
 8007b8dcd223f1ae0d02407bfd3a06b7dfdfb544 5016 rlwrap_0.41-1.debian.tar.xz
Checksums-Sha256:
 4b16c9a5e532767455b019db97b136c5a6a3d301a7cbace734c6cceea8c0318a 1866 rlwrap_0.41-1.dsc
 34497647b68df4ee031acf4ef80c09c79fe02b9027e8988a64e13f9ebc17c20a 259472 rlwrap_0.41.orig.tar.gz
 e3d0a5586aca8f0828fb4b3c116d71d305369a9cbb1047edd3080bf6d1706884 5016 rlwrap_0.41-1.debian.tar.xz
Files:
 3c107ecea11f39dde00f73f43d36d20c 1866 utils optional rlwrap_0.41-1.dsc
 8d1f3f8e634d55725645e6750c54e5f2 259472 utils optional rlwrap_0.41.orig.tar.gz
 e0013e1f423620c0d3cae69ea79a7fec 5016 utils optional rlwrap_0.41-1.debian.tar.xz

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJUEoULAAoJECj6gBpDvdY3+xUQAK4OyyXpUPck8MWTAPk+umWO
7LPlIEKVVStvcTz8PebQz6jQqhbv4Th6EoONHGO1N+HDM2T5902iCvGuK6XyxHfJ
LqC0Jxhamo9DrGQ9sm+yLqukzFHNcWEDs0evAVSCKP2kaVicKnZpVQq6x4gHIoef
TTPGcY1hcatZSs9SzWtzdN0PKl7arp/j9wW5gLdxH/yqYmbEBuwFzx3Dkhz32DWk
UyRWzK+frqyI+/CV5k9Rk6UaM/leYuKqsX59AG5diIl9nYaK1si8M8jKm2XtJ2k2
A4DKQfQFOVACETSyHFcZ4Gxv56wZtI7X1eWro/5oQ/qM68mmvp72kML5+fobAM4x
O+QjoFyjaRz7Cq5QSN5LmavtOsOOCOu+ADii/AFYjlVY7QZ8MEjpo4QDtcD+Rjn/
kWGR65JtcRiv+89H7Muo+j9Tw11tmWrt2eTTjYXpWjDidzpN3yCUfph8wzVKar9C
8Su3Bumpc9XT76FFt+ZhXdnXdoBnneuuHEbmC/RDnrJ84VlPqW4c9cf0MxgChGs9
bHLDrEGOfMfMZOAHfVbDoOLjU+lfgFYJkFEgNX7RCuvsqZdv8zr8+Wbhpkg381j4
PzfJg7Jt560VC6403SAR+a7yezcwKS08YQMF4BIj39OvLbfY0Ckepy2cMyIbAv1J
7ZLF7Uj1ZeTgJcdrN/1h
=LDLT
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Wed, 15 Oct 2014 07:35:02 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sun Jul 2 06:30:08 2023; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.