Skip Menu |
 

This queue is for tickets about the DBI CPAN distribution.

Report information
The Basics
Id: 81516
Status: resolved
Priority: 0/
Queue: DBI

People
Owner: Nobody in particular
Requestors: ANDK [...] cpan.org
bowtie [...] cpan.org
bitcard.org [...] perl.tgape.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in:
  • 1.622
  • 1.622_921
Fixed in: (no value)



Subject: Intermittent bug with DBD::File, detected by t/51dbm_file.t
Download (untitled) / with headers
text/plain 1.6k
t/51dbm_file.t test 12 attempts to use dbm_tables to reconnect. If the dbm_tables hash entry from %$attr is processed before the f_dir hash entry, it will attempt to open the database from the current directory instead of the specified director. I've verified this bug afflicts perl versions 5.8.1 to 5.12.2. However, it looks like it would afflict all of them. One can cause this bug to always trigger by adding dbm_tables to the $two_phased_init initial foreach loop (before f_dir if you've already applied my patch). My fix is to simply include f_dir in the %$attr keys to process first. This was from DBI-1.616, downloaded from CPAN last night. Perl versions 5.8.1, 5.8.2, 5.8.3, 5.8.4, 5.8.5, 5.8.6, 5.8.7, 5.8.8, 5.8.9, 5.10.0, 5.10.1, 5.12.0, 5.12.1, 5.12.2 Linux dhcppc0 2.6.33.7-eg #4 PREEMPT Sat Oct 30 14:14:41 EDT 2010 i686 i686 i386 GNU/Linux % /home/perl5/12.2/bin/perl -Iblib/lib t/51dbm_file.t ok 1 - drop table ok 2 - FRED.dir exists ok 3 - fred.dir exists ok 4 - fred.pag exists ok 5 - insert into mixed case table ok 6 - insert into uppercase table ok 7 - rows found via cloned mixed case table ok 8 - drop table ok 9 - rows found via mixed case table ok 10 # skip quoted identifiers aren't supported by DBI::SQL::Nano ok 11 - disconnect DBD::DBM::db selectall_arrayref failed: Cannot open /home/perl5/.cpan/build/DBI-1.616/fred.lck: No such file or directory (2) at blib/lib/DBD/File.pm line 730 at blib/lib/DBI/DBD/SqlEngine.pm line 796 [for Statement "select * from Fred"] at t/51dbm_file.t line 122. Can't use an undefined value as an ARRAY reference at t/51dbm_file.t line 123. # Tests were run but no plan was declared and done_testing() was not seen. %
Subject: SqlEngine.diff
Download SqlEngine.diff
text/x-diff 451b
--- lib/DBI/DBD/SqlEngine.pm 2010-12-21 18:00:15.000000000 -0500 +++ blib/lib/DBI/DBD/SqlEngine.pm 2011-08-21 16:53:28.630637110 -0400 @@ -174,7 +174,7 @@ if ($two_phased_init) { - foreach $a (qw(Profile RaiseError PrintError AutoCommit)) + foreach $a (qw(Profile RaiseError PrintError AutoCommit f_dir)) { # do these first exists $attr->{$a} or next; eval {
From: bitcard.org [...] perl.tgape.org
Download (untitled) / with headers
text/plain 225b
Did this bug get looked over because I failed to explicitly state that the attachment is a patch to fix the bug? Or is there another reason? If it's another reason, could someone let me know, so I can attempt to address it?
Download (untitled) / with headers
text/plain 511b
I tested the DBI trunk with Perl 5.14.2 and 5.10.1, both threaded, on Ubuntu 10.04/amd64. Both test runs succeeded without error. Taking a look into DBI-1.617's test reports showed that only some Linux machines (probably your's?) report that issue. Without more details what's going wrong I tend to ignoring the patch, because it might only fix symptoms - not the reason. If you have a machine which continues failing and still fails with DBI trunk, please help me to reproduce the issue. Best regards, Jens
Download (untitled) / with headers
text/plain 154b
No feedback since half a year and cannot be reproduced. Marking it stalled so far and keep in mind to close it later when no new information are provided.
Subject: Test failures due to hash randomisation in perl 5.17.6
Download (untitled) / with headers
text/plain 428b
Since bleadperl v5.17.5-518-g7dc8663 your tests are failing. That commit introduced hash key randomization and it seems at least the test t/51dbm_file.t is hit by that. Find a sample fail report at: http://www.cpantesters.org/cpan/ report/6f8af7be-32bb-11e2-9f28-2edaa290f8f5 You can read more about the commit at http://perl5.git.perl.org/perl .git/commit/7dc8663964c66a698d 31bbdc8e8abed69bddeec3 HTH&&Thanks&&Regards,
Download (untitled) / with headers
text/plain 3.5k
I brewed me a 5.17.6 and got following result: $ make && perl -Mblib t/51dbm_file.t Manifying blib/man1/dbiproxy.1 Manifying blib/man1/dbiprof.1 ok 1 - drop table ok 2 - FRED.dir exists ok 3 - fred.dir exists ok 4 - fred.pag exists ok 5 - insert into mixed case table ok 6 - insert into uppercase table ok 7 - rows found via cloned mixed case table ok 8 - drop table ok 9 - rows found via mixed case table ok 10 - rows found via select via fully qualified path ok 11 - disconnect ok 12 - rows found after reconnect using "dbm_tables" ok 13 - drop table ok 14 - fred.dir removed ok 15 - fred.pag removed 1..15 ernie:DBI.sqlengine sno$ perl -V Summary of my perl5 (revision 5 version 17 subversion 6) configuration: Platform: osname=darwin, osvers=12.2.1, archname=darwin-2level uname='darwin ernie.muppets.liwing.de 12.2.1 darwin kernel version 12.2.1: thu oct 18 16:32:48 pdt 2012; root:xnu-2050.20.9~2release_x86_64 x86_64 ' config_args='-de -Dprefix=/Users/sno/perl5/perlbrew/perls/perl-5.17.6 -Dusedevel -Aeval:scriptdir=/Users/sno/perl5/perlbrew/perls/perl-5.17.6/bin' hint=recommended, useposix=true, d_sigaction=define useithreads=undef, usemultiplicity=undef useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef use64bitint=define, use64bitall=define, uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include', optimize='-O3', cppflags='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include' ccversion='', gccversion='4.2.1 Compatible Apple Clang 4.1 ((tags/Apple/clang-421.11.66))', 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='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -fstack-protector -L/usr/local/lib' libpth=/usr/local/lib /usr/lib libs=-ldbm -ldl -lm -lutil -lc perllibs=-ldl -lm -lutil -lc libc=, so=dylib, useshrplib=false, libperl=libperl.a gnulibc_version='' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' ' cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -L/usr/local/lib -fstack-protector' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES PERLIO_LAYERS PERL_DONT_CREATE_GVSV PERL_MALLOC_WRAP PERL_PRESERVE_IVUV PERL_USE_DEVEL USE_64_BIT_ALL USE_64_BIT_INT USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_PERLIO USE_PERL_ATOF Built under darwin Compiled at Nov 29 2012 20:28:51 %ENV: PERLBREW_BASHRC_VERSION="0.54" PERLBREW_HOME="/Users/sno/.perlbrew" PERLBREW_MANPATH="/Users/sno/perl5/perlbrew/perls/perl-5.17.6/man" PERLBREW_PATH="/Users/sno/perl5/perlbrew/bin:/Users/sno/perl5/perlbrew/perls/perl-5.17.6/bin" PERLBREW_PERL="perl-5.17.6" PERLBREW_ROOT="/Users/sno/perl5/perlbrew" PERLBREW_VERSION="0.54" @INC: /Users/sno/perl5/perlbrew/perls/perl-5.17.6/lib/site_perl/5.17.6/darwin-2level /Users/sno/perl5/perlbrew/perls/perl-5.17.6/lib/site_perl/5.17.6 /Users/sno/perl5/perlbrew/perls/perl-5.17.6/lib/5.17.6/darwin-2level /Users/sno/perl5/perlbrew/perls/perl-5.17.6/lib/5.17.6 . Does it happen on Linux only? Or only with gcc?
Download (untitled) / with headers
text/plain 144b
It is a randomization impact. I'd expect that if you keep trying you will get a fail. At least, this is what I experienced with this DBI test.
Download (untitled) / with headers
text/plain 265b
On Fri Oct 05 09:09:54 2012, REHSACK wrote: Show quoted text
> No feedback since half a year and cannot be reproduced. Marking it > stalled so far and keep in mind to close it later when no new > information are provided.
This bug is identical to 81516, merge them when convenient.
Download (untitled) / with headers
text/plain 458b
On Tue Dec 04 09:49:19 2012, RIBASUSHI wrote: Show quoted text
> On Fri Oct 05 09:09:54 2012, REHSACK wrote:
> > No feedback since half a year and cannot be reproduced. Marking it > > stalled so far and keep in mind to close it later when no new > > information are provided.
> > This bug is identical to 81516, merge them when convenient.
You're absolutely right, Ribasushi - great to remind us. I asked myself why I couldn't reproduce #70401, but meanwhile I understand.
Merging intp RT#81516 as suggested by riba.
RT-Send-CC: bitcard.org [...] perl.tgape.org
Download (untitled) / with headers
text/plain 261b
Hi! Intermediate update: The patch above from bitcard.org@perl.tgape.org reliably fixes t/*51dbm_file.t but breaks t/*85gofer.t and t/*19fhtrace.t. (DBI 1.622) Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
RT-Send-CC: bitcard.org [...] perl.tgape.org
Download (untitled) / with headers
text/plain 415b
On Wed Dec 12 05:52:14 2012, SCHWIGON wrote: Show quoted text
> The patch above from bitcard.org@perl.tgape.org reliably > fixes t/*51dbm_file.t but breaks t/*85gofer.t and t/*19fhtrace.t.
The patch just works fine with Perl 5.17.6. The other issues were not related but only occurred on one of my machines. Sorry for the confusion. Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Download (untitled) / with headers
text/plain 269b
Steffen, thanks for that suggestion. We reviewed the patch and can confirm that it only fixes a symptom, not the really issue. For sure - the test passes after the patch is applied, but the problem don't disappear. We're working on it. Thanks for your patience, Jens
Download (untitled) / with headers
text/plain 248b
On 13.12.12 15:09, H.Merijn Brand wrote: Show quoted text
> After some discussion on IRC, we agreed on this: > > http://svn.perl.org/viewvc/modules?view=revision&revision=15511 > > which is likely to be integrated into the main trunk and released > the next DBI.
Subject: test failures in perl 5.17.7
Download (untitled) / with headers
text/plain 1.8k
t/50dbm_simple.t ................ ok DBD::DBM::db selectall_arrayref failed: Cannot open /home/kevin/.cpan/build/DBI-1.622-2kgnuK/fred.lck: No such file or directory (2) at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBD/File.pm line 730. at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBI/DBD/SqlEngine.pm line 796. [for Statement "select * from Fred"] at t/51dbm_file.t line 122. Can't use an undefined value as an ARRAY reference at t/51dbm_file.t line 123. # Tests were run but no plan was declared and done_testing() was not seen. t/zvp_50dbm_simple.t ............ ok DBD::DBM::db selectall_arrayref failed: Cannot open /home/kevin/.cpan/build/DBI-1.622-2kgnuK/fred.lck: No such file or directory (2) at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBD/File.pm line 730. at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBI/DBD/SqlEngine.pm line 796. [for Statement "select * from Fred"] at ./t/51dbm_file.t line 122. Can't use an undefined value as an ARRAY reference at ./t/51dbm_file.t line 123. Compilation failed in require at t/zvp_51dbm_file.t line 4. # Tests were run but no plan was declared and done_testing() was not seen. t/zvxnp_50dbm_simple.t .......... ok DBD::DBM::db selectall_arrayref failed: Cannot open /home/kevin/.cpan/build/DBI-1.622-2kgnuK/fred.lck: No such file or directory (2) at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBD/File.pm line 730. at /home/kevin/.cpan/build/DBI-1.622-2kgnuK/blib/lib/DBI/DBD/SqlEngine.pm line 796. [for Statement "select * from Fred"] at ./t/51dbm_file.t line 122. Can't use an undefined value as an ARRAY reference at ./t/51dbm_file.t line 123. Compilation failed in require at t/zvxnp_51dbm_file.t line 6. # Tests were run but no plan was declared and done_testing() was not seen. t/zvxnp_51dbm_file.t ............ Dubious, test returned 2 (wstat 512, 0x200)
Fixed. Thanks!


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.