Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bleadperl v5.17.0-559-g6b24a4b breaks tab completion in debugger #12296

Closed
p5pRT opened this issue Jul 27, 2012 · 14 comments
Closed

Bleadperl v5.17.0-559-g6b24a4b breaks tab completion in debugger #12296

p5pRT opened this issue Jul 27, 2012 · 14 comments

Comments

@p5pRT
Copy link

p5pRT commented Jul 27, 2012

Migrated from rt.perl.org#114284 (status was 'resolved')

Searchable as RT114284$

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From @andk

Git bisect


commit 6b24a4b
Author​: Shlomi Fish <shlomif@​shlomifish.org>
Date​: Mon Jun 18 00​:05​:28 2012 +0300

  add use strict to perl -d

Description


Bug requires Term​::ReadLine​::Perl or equivalent installed. In the
following the string "<TAB>" denotes the pressing of the TAB key.

Up to v5.17.0-558-g7e28696 TAB-completion of global variables worked.
Entering something like C<< x $DB​::<TAB> >> produced a list of all
scalars available. This stopped working in v5.17.0-559-g6b24a4b. It is
still broken in v5.17.2-81-g613c63b.

% perl -de0

Loading DB routines from perl5db.pl version 1.39
Editor support available.

Enter h or 'h h' for help, or 'man perldebug' for more help.

main​::(-e​:1)​: 0
DB<1> x $DB​::<TAB>Can't use string ("package") as a SCALAR ref while "strict refs" in use at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 8496.
at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 8496.
  DB​::db_complete('$DB​::', 'x $DB​::', 2) called at sub readline​::completion_matches line 10
  readline​::completion_matches('CODE(0x20a8a30)', '$DB​::', 'x $DB​::', 2) called at sub readline​::complete_internal line 27
  readline​::complete_internal('\x{9}') called at sub readline​::F_Complete line 16
  readline​::F_Complete(1, 9) called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0/Term/ReadLine/readline.pm line 1669
  readline​::readline(' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0/Term/ReadLine/Perl.pm line 11
  Term​::ReadLine​::Perl​::readline('Term​::ReadLine​::Perl=ARRAY(0x1d4c218)', ' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 6569
  DB​::readline(' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 2121
  DB​::DB called at -e line 1
Debugged program terminated. Use q to quit or R to restart,
  use o inhibit_exit to avoid stopping after program termination,
  h q, h R or h o to get additional info.

perl -V


Summary of my perl5 (revision 5 version 17 subversion 0) configuration​:
  Commit id​: 6b24a4b
  Platform​:
  osname=linux, osvers=3.2.0-2-amd64, archname=x86_64-linux-thread-multi-ld
  uname='linux k83 3.2.0-2-amd64 #1 smp mon may 21 17​:45​:41 utc 2012 x86_64 gnulinux '
  config_args='-Dprefix=/home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da -Dmyhostname=k83 -Dinstallusrbinperl=n -Uversiononly -Dusedevel -des -Ui_db -Duseithreads -Duselongdouble -DDEBUGGING=-g'
  hint=recommended, useposix=true, d_sigaction=define
  useithreads=define, usemultiplicity=define
  useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
  use64bitint=define, use64bitall=define, uselongdouble=define
  usemymalloc=n, bincompat5005=undef
  Compiler​:
  cc='cc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
  optimize='-O2 -g',
  cppflags='-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
  ccversion='', gccversion='4.7.0', gccosandvers=''
  intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
  d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
  ivtype='long', ivsize=8, nvtype='long double', nvsize=16, Off_t='off_t', lseeksize=8
  alignbytes=16, prototype=define
  Linker and Libraries​:
  ld='cc', ldflags =' -fstack-protector -L/usr/local/lib'
  libpth=/usr/local/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib /usr/lib
  libs=-lnsl -ldb -ldl -lm -lcrypt -lutil -lpthread -lc
  perllibs=-lnsl -ldl -lm -lcrypt -lutil -lpthread -lc
  libc=, so=so, useshrplib=false, libperl=libperl.a
  gnulibc_version='2.13'
  Dynamic Linking​:
  dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
  cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib -fstack-protector'

Characteristics of this binary (from libperl)​:
  Compile-time options​: HAS_TIMES MULTIPLICITY PERLIO_LAYERS
  PERL_DONT_CREATE_GVSV PERL_IMPLICIT_CONTEXT
  PERL_MALLOC_WRAP PERL_PRESERVE_IVUV PERL_USE_DEVEL
  USE_64_BIT_ALL USE_64_BIT_INT USE_ITHREADS
  USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE
  USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LONG_DOUBLE
  USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API
  Built under linux
  Compiled at Jun 17 2012 23​:39​:39
  @​INC​:
  /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0/x86_64-linux-thread-multi-ld
  /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0
  /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/x86_64-linux-thread-multi-ld
  /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0
  .

--
andreas

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From perl@profvince.com

On 27/07/2012 11​:57, (Andreas J. Koenig) (via RT) wrote​:

# New Ticket Created by (Andreas J. Koenig)
# Please include the string​: [perl #114284]
# in the subject line of all future correspondence about this issue.
# <URL​: https://rt-archive.perl.org/perl5/Ticket/Display.html?id=114284 >

Git bisect
----------
commit 6b24a4b
Author​: Shlomi Fish <shlomif@​shlomifish.org>
Date​: Mon Jun 18 00​:05​:28 2012 +0300

 add use strict to perl \-d

Description
-----------
Bug requires Term​::ReadLine​::Perl or equivalent installed. In the
following the string "<TAB>" denotes the pressing of the TAB key.

Up to v5.17.0-558-g7e28696 TAB-completion of global variables worked.
Entering something like C<< x $DB​::<TAB> >> produced a list of all
scalars available. This stopped working in v5.17.0-559-g6b24a4b. It is
still broken in v5.17.2-81-g613c63b.

% perl -de0

Loading DB routines from perl5db.pl version 1.39
Editor support available.

Enter h or 'h h' for help, or 'man perldebug' for more help.

main​::(-e​:1)​: 0
DB<1> x $DB​::<TAB>Can't use string ("package") as a SCALAR ref while "strict refs" in use at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 8496.
at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 8496.
DB​::db_complete('$DB​::', 'x $DB​::', 2) called at sub readline​::completion_matches line 10
readline​::completion_matches('CODE(0x20a8a30)', '$DB​::', 'x $DB​::', 2) called at sub readline​::complete_internal line 27
readline​::complete_internal('\x{9}') called at sub readline​::F_Complete line 16
readline​::F_Complete(1, 9) called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0/Term/ReadLine/readline.pm line 1669
readline​::readline(' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/site_perl/5.17.0/Term/ReadLine/Perl.pm line 11
Term​::ReadLine​::Perl​::readline('Term​::ReadLine​::Perl=ARRAY(0x1d4c218)', ' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 6569
DB​::readline(' DB<1> ') called at /home/src/perl/repoperls/installed-perls/perl/v5.17.0-559-g6b24a4b/a2da/lib/5.17.0/perl5db.pl line 2121
DB​::DB called at -e line 1
Debugged program terminated. Use q to quit or R to restart,
use o inhibit_exit to avoid stopping after program termination,
h q, h R or h o to get additional info.

This should have been fixed by commit 9df8bd1 (which is in 5.17.2).

Vincent

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From perl@profvince.com

On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in 5.17.2).

Or more likely by ea7bdd8 for this specific issue (tab completion was
broken in several places)

Vincent

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From @andk

On Fri, 27 Jul 2012 05​:37​:33 -0700, "perl@​profvince.com via RT" <perlbug-followup@​perl.org> said​:

  > On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in 5.17.2).

  > Or more likely by ea7bdd8 for this specific issue (tab completion was
  > broken in several places)

Not here. For me, the example I posted works neither with 9df8bd1 nor
ea7bdd8 nor with pretty recent bleadperl v5.17.2-81-g613c63b.

--
andreas

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From @shlomif

On Fri Jul 27 13​:07​:36 2012, andreas.koenig.7os6VVqR@​franz.ak.mind.de wrote​:

On Fri, 27 Jul 2012 05​:37​:33 -0700, "perl@​profvince.com via RT"
<perlbug-followup@​perl.org> said​:

On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in
5.17.2).

Or more likely by ea7bdd8 for this specific issue (tab
completion was
broken in several places)

Not here. For me, the example I posted works neither with 9df8bd1 nor
ea7bdd8 nor with pretty recent bleadperl v5.17.2-81-g613c63b.

There problem is that there is now a different error. The attached patch
appears to fix it.

Regards,

-- Shlomi Fish

@p5pRT
Copy link
Author

p5pRT commented Jul 27, 2012

From @shlomif

git.diff
diff --git a/lib/perl5db.pl b/lib/perl5db.pl
index f07467f..244ae10 100644
--- a/lib/perl5db.pl
+++ b/lib/perl5db.pl
@@ -8667,8 +8667,11 @@ Look through all the symbols in the package. C<grep> out all the possible hashes
 
 =cut
 
-        my @out = map "$prefix$_", grep /^\Q$text/, grep /^_?[a-zA-Z]/,
-          keys %$pack;
+        my @out = do {
+            no strict 'refs';
+            map "$prefix$_", grep /^\Q$text/, grep /^_?[a-zA-Z]/,
+            keys %$pack;
+        };
 
 =pod
 

@p5pRT
Copy link
Author

p5pRT commented Aug 6, 2012

From @shlomif

Hi all,

On Fri Jul 27 14​:28​:55 2012, shlomif wrote​:

On Fri Jul 27 13​:07​:36 2012, andreas.koenig.7os6VVqR@​franz.ak.mind.de
wrote​:

On Fri, 27 Jul 2012 05​:37​:33 -0700, "perl@​profvince.com via RT"
<perlbug-followup@​perl.org> said​:

On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in
5.17.2).

Or more likely by ea7bdd8 for this specific issue (tab
completion was
broken in several places)

Not here. For me, the example I posted works neither with 9df8bd1 nor
ea7bdd8 nor with pretty recent bleadperl v5.17.2-81-g613c63b.

There problem is that there is now a different error. The attached patch
appears to fix it.

Regards,

-- Shlomi Fish

Shouldn't this patch be applied and this bug report closed? Or are you
waiting for something else. Ping.

Regards,

-- Shlomi Fish

@p5pRT
Copy link
Author

p5pRT commented Sep 2, 2012

From @shlomif

Hi all,

On Mon Aug 06 02​:29​:34 2012, shlomif wrote​:

Hi all,

On Fri Jul 27 14​:28​:55 2012, shlomif wrote​:

On Fri Jul 27 13​:07​:36 2012, andreas.koenig.7os6VVqR@​franz.ak.mind.de
wrote​:

On Fri, 27 Jul 2012 05​:37​:33 -0700, "perl@​profvince.com via RT"
<perlbug-followup@​perl.org> said​:

On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in
5.17.2).

Or more likely by ea7bdd8 for this specific issue (tab
completion was
broken in several places)

Not here. For me, the example I posted works neither with 9df8bd1 nor
ea7bdd8 nor with pretty recent bleadperl v5.17.2-81-g613c63b.

There problem is that there is now a different error. The attached patch
appears to fix it.

Regards,

-- Shlomi Fish

Shouldn't this patch be applied and this bug report closed? Or are you
waiting for something else. Ping.

Please apply this patch or let me know how it should be improved. It has
been roughly a month since my last comment.

Regards,

-- Shlomi Fish

@p5pRT
Copy link
Author

p5pRT commented Sep 4, 2012

From @cpansprout

On Sun Sep 02 00​:20​:10 2012, shlomif wrote​:

Hi all,

On Mon Aug 06 02​:29​:34 2012, shlomif wrote​:

Hi all,

On Fri Jul 27 14​:28​:55 2012, shlomif wrote​:

On Fri Jul 27 13​:07​:36 2012, andreas.koenig.7os6VVqR@​franz.ak.mind.de
wrote​:

On Fri, 27 Jul 2012 05​:37​:33 -0700, "perl@​profvince.com
via RT"
<perlbug-followup@​perl.org> said​:

On 27/07/2012 14​:31, Vincent Pit wrote​:

This should have been fixed by commit 9df8bd1 (which is in
5.17.2).

Or more likely by ea7bdd8 for this specific issue (tab
completion was
broken in several places)

Not here. For me, the example I posted works neither with
9df8bd1 nor
ea7bdd8 nor with pretty recent bleadperl v5.17.2-81-g613c63b.

There problem is that there is now a different error. The attached
patch
appears to fix it.

Regards,

-- Shlomi Fish

Shouldn't this patch be applied and this bug report closed? Or are you
waiting for something else. Ping.

Please apply this patch or let me know how it should be improved. It has
been roughly a month since my last comment.

Every time I have touched perl5db.pl (even applying someone else’s
patch), I have caused problems.

So I am hoping someone else will step up and handle this. Anyone?

--

Father Chrysostomos

@p5pRT
Copy link
Author

p5pRT commented Sep 4, 2012

From @rjbs

* Father Chrysostomos via RT <perlbug-followup@​perl.org> [2012-09-04T00​:37​:30]

patch), I have caused problems.

So I am hoping someone else will step up and handle this. Anyone?

I will deal with the outstanding perl5db patches from Shlomi today or tomorrow.
I know of this one and one more.

--
rjbs

@p5pRT
Copy link
Author

p5pRT commented Sep 5, 2012

From @rjbs

Thanks, applied (tentatively, locally) as 32050a6.

@p5pRT
Copy link
Author

p5pRT commented Sep 5, 2012

From [Unknown Contact. See original ticket]

Thanks, applied (tentatively, locally) as 32050a6.

@p5pRT
Copy link
Author

p5pRT commented Sep 5, 2012

@rjbs - Status changed from 'open' to 'resolved'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant