Tracker: Bugs

5 perl5db.pl did not return a true value - ID: 2907155
Last Update: Comment added ( nobody )

When I try to debug perl programs, I get the following message:

Use of uninitialized value in subroutine dereference at (null) line 1.
perl5db.pl did not return a true value.
BEGIN failed--compilation aborted.


nponeccop@livejournal ( nponeccop@livejournal ) - 2009-12-01 14:59:08 PST

5

Open

None

Stephan Ruehl

Debugger

v0.6.x

Public


Comments ( 29 )

Date: 2012-06-11 04:48:09 PDT
Sender: nobody

Installing PathTools 3.39.1 fixed the problem for me.
Config : ActivePerl 5.14 + Win 7 + EPIC 0.6.44
Fr,


Date: 2012-04-17 06:27:27 PDT
Sender: nobody

> How about perl -e 'use Cwd; print $Cwd::VERSION'
It says 3.33.

There doesn't seem to be a newer version available through PPM. If I do

ppm upgrade Cwd

I get *** no upgrades available for Cwd ***

But I was able to upgrade to Cwd 3.39 using cpanp, and now the debugger
works fine in Eclipse.

Thx for the pointer.

Alain


Date: 2012-04-17 05:14:36 PDT
Sender: jploskiProject AdminAccepting Donations

How about perl -e 'use Cwd; print $Cwd::VERSION'


Date: 2012-04-17 05:08:30 PDT
Sender: nobody

In response to jploski, when I do perl -v, I get:

---
This is perl 5, version 12, subversion 3 (v5.12.3) built for
MSWin32-x86-multi-thread
(with 9 registered patches, see perl -V for more detail)
etc...
---

I'm running on Windows 7, 64bit, but am using 32bit version of ActiveState.


Date: 2012-04-17 04:43:43 PDT
Sender: jploskiProject AdminAccepting Donations

https://rt.cpan.org/Public/Bug/Display.html?id=56225

It sounds like version 3.37 of Cwd.pm contains a bug fix/workaround - and
apparently a cleverer one than the hack proposed here - but maybe it's not
yet available from ActiveState repository? Which version do you have on
your system?


Date: 2012-04-17 04:26:26 PDT
Sender: nobody

Nevermind my comment of 2012-04-03.

I had misunderstood the fix. I thought I needed to ADD the eval '' around
the faulty line. I now understand that I need to REMOVE it. When I do this,
the debugger works.

I also tried a suggestion made by someone else, of replacing the eval ''
with eval {}. That works too, and I went with that in the end, because it
seems closer to the original intent of the line.

Is there a reason why this fix can't be added to the official version of
Cmd.pm? This bug has been reported over 2 years ago!


Date: 2012-04-03 05:02:00 PDT
Sender: alain_desilets

I have that same problem on Win32. Looking at C:/Perl/lib/Cwd.pm, I see
that the method _win32_cwd already contains the supposed fix:

---
sub _win32_cwd {
if (eval 'defined &DynaLoader::boot_DynaLoader') {
---

Yet, I still get the error. I tried adding C:/Perl/lib to the Perl Include
Path, and it did allow me to start the debugger. But as pointed out by
other folks, breakpoints stop working.

Just for fun today, I installed Komodo, and the debugger ran out of the
box. Makes me thing seriously about switching to Komodo.


Date: 2010-12-06 03:48:35 PST
Sender: jploskiProject AdminAccepting Donations

It's not really a major bug because of the trivial workaround that can be
applied outside of EPIC, as also described in the FAQ:
http://www.epic-ide.org/faq.php#debug

On the other hand, a fix in EPIC would be non-trivial. If you want to give
it a try yourself, you can send me a patch.


Date: 2010-12-06 03:38:22 PST
Sender: duartemolha

I still cannot believe this is not resolved are we so few people using epic
that a major bug has not yet been fixed???!!!


Date: 2010-09-16 02:43:53 PDT
Sender: nobody

Yes editing just the cwd file to remove eval works, thanks


Date: 2010-08-06 13:56:48 PDT
Sender: jploskiProject AdminAccepting Donations

Adding Perl's 'lib' directory to a project's include path is definitely a
bad workaround, as it makes EPIC ignore all breakpoints by forcing it to
pick up Perl's perl5db.pl rather than EPIC's own patched version. It also
produces an error regarding an undefined subroutine "add_breakpoints" in
the debugger console.

To work around this bug, you should definitely edit Cwd.pm as suggested
here or in my RT bug report.


Date: 2010-06-22 02:43:32 PDT
Sender: raoraghuba

Modifying Cwd.pm has NOT worked for me but including path 'C:\Perl\lib' in
perl search path has worked for me.:):):)


Date: 2010-05-08 12:16:41 PDT
Sender: nobody

I encountered this problem using Fedora. My problem was a hosts/hostname
issue. A DNS query on the hostname of the machine returns a static IP that
wasn't this machine. By adding a line that maps 127.0.0.1 to the hostname
in hosts, everything worked fine. Hope that helps somebody else!


Date: 2010-04-02 05:46:03 PDT
Sender: jploskiProject AdminAccepting Donations

I created a ticket for PathTools regarding this bug:
https://rt.cpan.org/Public/Bug/Display.html?id=56225


Date: 2010-03-19 07:55:31 PDT
Sender: nobody

same as i upgraded to perl 5.10.1 build 1007. editing Cwd package fixes
the problem. thanks are directed to gkello. 'booo' to authors of Cwd.


Date: 2010-03-09 15:42:23 PST
Sender: adamwozpl

Damn, I forgot to emphasize in my previous post, that my main and only aim
was to **DEBUG** perl scripts using EPIC IDE :)


Date: 2010-03-09 15:40:47 PST
Sender: adamwozpl

Hi

My config:
EPIC 0.6.35
Strawberry Perl 5.10.1.1
OS: Vista 32 bits

I have applied all possible tips mentioned in this thread (thank you for
them!) but using Strawberry Perl with no luck :(

After several hours I have:
* uninstalled Strawberry Perl
* installed ActivePerl
* installed ActivePerl PadWalker using: ppm PadWalker
* applied gkello tip

... and everything went fine! Thanks!

Regards, Adaslaw


Date: 2010-02-13 03:32:31 PST
Sender: normington

last comment was me (forgot to login)


Date: 2010-02-13 03:31:31 PST
Sender: nobody

Modifing Cwd.pm also worked for me. Are there going to be any problems
doing this?

I have also noticed that the perl5db.pl is copied and modified each time a
program debug is launched from EPIC so it is not really a private version.
It adds a single line that allows EPIC to do breakpoint handling


Date: 2010-02-11 03:29:33 PST
Sender: edvin

Fixing Cwd.pm and deleting Perl\lib from the Perl Include Path works for me
too.


Date: 2010-02-11 00:39:10 PST
Sender: neekfenwick

gkello, good point, I did find that after modifying my include path
debugging could begin, and execution was halted on the first line of the
program as normal, but none of my breakpoints stopped the program. With
the Cwd.pm fix, and no modification to the project include path,
breakpoints work as expected. I didn't realise there was a hidden version
of perl5db.pl with epic.


Date: 2010-02-10 23:45:43 PST
Sender: gkello

Note that epic has it's own, a little bit modified, copy of perl5db.pl in
[EclipeWorkSpace]\.metadata\.plugins\org.epic.debug\ folder. So if You
change the project include path then You will most likely loose some epic
breakpoint handling functionality.


Date: 2010-02-10 20:58:49 PST
Sender: neekfenwick

Thanks gkello and edvin, your fixes both worked for me, using ActiveState
5.10.1 perl on Vista. laismeuchi, are you not reading those other
comments? :)


Date: 2010-02-10 11:45:01 PST
Sender: laismeuchi

Hi,

I got the same problem, and can't solve. Anyone got it?

tanks


Date: 2010-02-08 01:08:19 PST
Sender: edvin

Including the path to the perl5db.pl file (Perl\lib directory) to the Perl
Include Path to my project (Project->Properties->Perl Include Path) works
for me.


Date: 2010-02-08 00:39:55 PST
Sender: edvin

I installed PadWalker with:

ppm install http://www.bribes.org/perl/ppm/PadWalker.ppd

and becomes the same error message.


Date: 2010-02-02 23:33:37 PST
Sender: gkello

It started to happen to me if I upgarde Cwd package from 3.30 -> 3.31
AND AFAIK only real change in the update was
sub _win32_cwd {
if (defined &DynaLoader::boot_DynaLoader) {
to
sub _win32_cwd {
if (eval 'defined &DynaLoader::boot_DynaLoader') {

Well, removing that "eval" makes debugger to work again


Date: 2009-12-30 02:02:30 PST
Sender: zaneuji

It happens to me too. Only recent I found that the problem is that I
installed PadWalker from CPAN. After reinstalled ActivePerl and then
PadWalker:
ppm install http://www.bribes.org/perl/ppm/PadWalker.ppd
, everything works just fine.

Still I don't know whether it's a EPIC bug or PadWalker bug.


Date: 2009-12-01 15:41:58 PST
Sender: nponeccop@livejournal

Windows, ActivePerl 5.10.1 (several different builds), local scripts, not
CGI


Attached File

No Files Currently Attached

Change

No changes have been made to this artifact.