-
Notifications
You must be signed in to change notification settings - Fork 16
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
Can't call method "get_next_key" on an undefined value at /usr/share/perl5/DBM/Deep/Engine.pm #6
Comments
Thought I'd try and simplify things. I have written a basic module and script to test this as simply as possible. This is on the Fedora 18 box previously mentioned. [jon@localhost CaravanCoding]$ ./deeptest.pl > results.txt I've 7 zipped up the script, the module, the DB, and the results.txt file. Just got to find out how to upload it. Hope this is useful - or at least eliminates a few things. |
Problem is also present in fresh installation of Raspbery flvaoured Debian (Raspbian). I've run up an install of Raspian (based on Debian Wheezy I believe) on the Pi, and installed the test scripts plus your module (apart from that completely fresh installation). Sadly, still got the same issue, so it would appear this problem is not confined to the Fedora stable. pi@raspberrypi ~/CaravanCodingFedTester11072013 $ uname -a This is perl 5, version 14, subversion 2 (v5.14.2) built for arm-linux-gnueabihf-thread-multi-64int Copyright 1987-2011, Larry Wall Perl may be copied only under the terms of either the Artistic License or the Complete documentation for Perl, including FAQ lists, should be found on pi@raspberrypi ~/CaravanCodingFedTester11072013 $ ./deeptest.pl > results.txt Platform: Characteristics of this binary (from libperl): |
I'm not a maintainer of this project, but what you've posted so far is pretty long. Would you be able to post a small example program that exhibits the problem? |
If this is still an issue with the latest release, please raise a ticket on DBM::Deep's new repo's issue tracker at https://github.com/DBM-Deep/DBM-Deep/issues, with complete instructions on how to replicate it. |
When trying to step through multi-level hashes I get "Can't call method "get_next_key" on an undefined value at /usr/share/perl5/DBM/Deep/Engine.pm" whenever I use "next_key".
I've built a Fedora 18 VM on ESXi to just double check that it IS a Raspberry Pi thing (as Pidora is based on F18), and it turns out - it's not....
Build is Fedora 18, 32-bit, from Live CD. I've installed XFCE and the necessary perl modules, plus I've compiled in the Audio:Scan module (which needed little more than make, gcc and zlib-devel).
Running exactly the same test script, as soon as I try to walk through the hash table I hit the problem (see below for output).
So this would seem to be unrelated to the fact I'm running on the Raspberry Pi, but something to do with Fedora 18? Anyway, thought you might want to know as I guess it's much easier for you to troubleshoot as I'm sure you can spin up an F18 locally pretty quickly.
[jon@localhost CaravanCoding]$ uname -a
Linux localhost.localdomain 3.9.6-200.fc18.i686 #1 SMP Thu Jun 13 19:29:40 UTC 2013 i686 i686 i386 GNU/Linux
[jon@localhost CaravanCoding]$ perl -v
This is perl 5, version 16, subversion 3 (v5.16.3) built for i386-linux-thread-multi
[jon@localhost CaravanCoding]$ perl -d musictest.pl
Loading DB routines from perl5db.pl version 1.37
Editor support available.
Enter h or 'h h' for help, or 'man perldebug' for more help.
defined(%hash) is deprecated at CecilMods/Music.pm line 1097.
at CecilMods/Music.pm line 1097.
require CecilMods/Music.pm called at musictest.pl line 11
main::BEGIN() called at CecilMods/Music.pm line 1097
eval {...} called at CecilMods/Music.pm line 1097
(Maybe you should just omit the defined()?)
at CecilMods/Music.pm line 1097.
require CecilMods/Music.pm called at musictest.pl line 11
main::BEGIN() called at CecilMods/Music.pm line 1097
eval {...} called at CecilMods/Music.pm line 1097
defined(%hash) is deprecated at CecilMods/Music.pm line 1188.
at CecilMods/Music.pm line 1188.
require CecilMods/Music.pm called at musictest.pl line 11
main::BEGIN() called at CecilMods/Music.pm line 1188
eval {...} called at CecilMods/Music.pm line 1188
(Maybe you should just omit the defined()?)
at CecilMods/Music.pm line 1188.
require CecilMods/Music.pm called at musictest.pl line 11
main::BEGIN() called at CecilMods/Music.pm line 1188
eval {...} called at CecilMods/Music.pm line 1188
CecilMods::Music is successfully loaded!
at CecilMods/Music.pm line 24.
require CecilMods/Music.pm called at musictest.pl line 11
main::BEGIN() called at CecilMods/Music.pm line 0
eval {...} called at CecilMods/Music.pm line 0
main::(musictest.pl:13): my $loop = Glib::MainLoop->new();
DB<1> c
CecilMods::Music DB unusable - reinitialising...
at CecilMods/Music.pm line 84.
Music::initialise('Music=HASH(0x9b1f1a0)') called at CecilMods/Music.pm line 72
Music::new('Music') called at musictest.pl line 15
Music object created
Data dumper says '.
$VAR1 = bless( {
'_QL_TRACKS' => [],
'_FF_NODE' => undef,
'_CURRENT_TRACK' => undef,
'_MDB' => bless( {
'TRACKTABLE' => bless( {}, 'DBM::Deep::Hash' ),
'ALBUMTABLE' => bless( {}, 'DBM::Deep::Hash' ),
'ARTALBTABLE' => bless( {}, 'DBM::Deep::Hash' ),
'ARTTRKTABLE' => bless( {}, 'DBM::Deep::Hash' ),
'SAVESTATE' => bless( {}, 'DBM::Deep::Hash' )
}, 'DBM::Deep::Hash' ),
'_PLAYLIST_MAXLEN' => 100,
'_DBFILE' => 'CecilMusicDB.db',
'_FILEREAD_POS' => 0,
'_PLAYLIST' => undef,
'_CURRENT_LENGTH' => undef,
'_FILEREAD_ACT' => 0,
'_FILEREAD_TOT' => 0,
'_PLAYER' => bless( {}, 'GStreamer::Pipeline' ),
'_CURRENT_POS' => undef,
'_QL_ARTISTS' => [],
'_FILEREAD_SUC' => 0,
'_MEDIA_DIR' => '/home/jon/Music/',
'_PLAYLIST_CHANGED' => 0,
'_STATE' => 'READY'
}, 'Music' );
Running FindFile Test
Supported media is: '.mp3','.m4a','.m4p','.mp4'
New Album : Dirt Disc: 1/1 - Alice In Chains
New Artist Found: Alice In Chains
New Album : Nothing Safe: Best Of The Box Disc: 1/1 - Alice In Chains
New Album : Rock In A Hard Place Disc: 1/1 - Aerosmith
New Artist Found: Aerosmith
New Album : Night In The Ruts Disc: 1/1 - Aerosmith
New Album : Permanent Vacation Disc: 1/1 - Aerosmith
New Album : Draw The Line Disc: 1/1 - Aerosmith
MUSIC MOD: Alice In Chains: DBM::Deep::Hash=HASH(0xb754850) retrieved. (this is the first_key - which points to a hash of albums by that Artist)
Can't call method "get_next_key" on an undefined value at /usr/share/perl5/vendor_perl/DBM/Deep/Engine.pm line 258.
at /usr/share/perl5/vendor_perl/DBM/Deep/Engine.pm line 258.
DBM::Deep::Engine::get_next_key('DBM::Deep::Engine::File=HASH(0xa4ea3c0)', 'DBM::Deep::Hash=HASH(0xb754520)', 'Alice In Chains') called at /usr/share/perl5/vendor_perl/DBM/Deep/Hash.pm line 97
DBM::Deep::Hash::NEXTKEY('DBM::Deep::Hash=HASH(0xa652b58)', 'Alice In Chains') called at /usr/share/perl5/vendor_perl/DBM/Deep/Hash.pm line 107
DBM::Deep::Hash::next_key('DBM::Deep::Hash=HASH(0xa652b58)', 'Alice In Chains') called at CecilMods/Music.pm line 637
Music::generate_ql_artists('Music=HASH(0x9b1f1a0)') called at CecilMods/Music.pm line 859
Music::scanmediadir('Music=HASH(0x9b1f1a0)') called at musictest.pl line 22
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.
DB<1> q
[jon@localhost CaravanCoding]$
The text was updated successfully, but these errors were encountered: