Skip Menu |

This queue is for tickets about the JSON-Path CPAN distribution.

Report information
The Basics
Id: 89393
Status: resolved
Priority: 0/
Queue: JSON-Path

People
Owner: perl [...] toby.ink
Requestors: henri-damien.laurent [...] fraudbuster.mobi
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Problem with Devel::ptkdb
Date: Thu, 10 Oct 2013 16:20:33 +0200
To: bug-JSON-Path [...] rt.cpan.org
From: Henri-Damien LAURENT <henri-damien.laurent [...] fraudbuster.mobi>
Hi, thanks for this Module which does great job. It appears that there is a problem when used in conjonction with Devel::ptkdb as debugger. test_jsonpath.pl : use strict; use warnings; use JSON::Path; my $object={"test"=>"me"}; my $jsonpath=JSON::Path->new('$.test'); my $a = $jsonpath->value($object); $ perl test_jsonpath.pl me $ perl -d:ptkdb test_jsonpath.pl JSON::Path::value is writeonly at /usr/share/perl5/Devel/ptkdb.pm line 4332. I think this is owed to the fact that value can be both written and read. But then, it is not clear to me where it should tell to the debugger that value can be read and write. Could you help in any way ? -- Henri-Damien LAURENT FraudBuster Mail : henri-damien.laurent@fraudbuster.mobi Mobile : +33 6 88 77 62 53 Skype : laurenthdl
Do you know if this is a general bug with Devel::ptkdb and lvalue subs? Or is it specific to JSON::Path? e.g. my $xxx = 42; my $XXX = sub :lvalue { $xxx };
Subject: Re: [rt.cpan.org #89393] Problem with Devel::ptkdb
Date: Fri, 11 Oct 2013 13:56:18 +0200
To: bug-JSON-Path [...] rt.cpan.org
From: Henri-Damien LAURENT <henri-damien.laurent [...] fraudbuster.mobi>
On 11/10/2013 12:47, Toby Inkster via RT wrote: Show quoted text
> my $xxx = 42; > my $XXX = sub :lvalue { $xxx };
Hi, thanks for you quick answer. Using this code does not raise any error with Devel::ptkdb. We are using JSON::Path::value to get a value, not to set the value. But I havenot looked at the internals. I donot know how Devel::ptkdb knows the types of values (writable or readable) nor how it is declared with lvalue function. -- Henri-Damien LAURENT FraudBuster Mail : henri-damien.laurent@fraudbuster.mobi Mobile : +33 6 88 77 62 53 Skype : laurenthdl
Subject: Re: [rt.cpan.org #89393] Problem with Devel::ptkdb
Date: Thu, 31 Oct 2013 17:12:19 +0100
To: bug-JSON-Path [...] rt.cpan.org
From: Henri-Damien LAURENT <henri-damien.laurent [...] fraudbuster.mobi>
On 11/10/2013 13:56, Henri-Damien LAURENT wrote: Show quoted text
> On 11/10/2013 12:47, Toby Inkster via RT wrote:
>> my $xxx = 42; >> my $XXX = sub :lvalue { $xxx };
> Hi, > thanks for you quick answer. > > Using this code does not raise any error with Devel::ptkdb. > > We are using JSON::Path::value to get a value, not to set the value. > But I havenot looked at the internals. I donot know how Devel::ptkdb > knows the types of values (writable or readable) nor how it is > declared with lvalue function. > >
Any hope to fix the problem ? -- Henri-Damien LAURENT FraudBuster Mail : henri-damien.laurent@fraudbuster.mobi Mobile : +33 6 88 77 62 53 Skype : laurenthdl
I currently suspect something in lvalue.pm, which JSON::Path relies on. I've been playing at writing a replacement for lvalue.pm because lvalue.pm has other issues. (It's slower than it could be, plus there's a module on CPAN called Lvalue.pm which can cause problem on case-insensitive file systems - i.e. Windows.)
Subject: Re: [rt.cpan.org #89393] Problem with Devel::ptkdb
Date: Fri, 01 Nov 2013 15:42:32 +0100
To: bug-JSON-Path [...] rt.cpan.org
From: Henri-Damien LAURENT <henri-damien.laurent [...] fraudbuster.mobi>
On 01/11/2013 14:58, Toby Inkster via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=89393 > > > I currently suspect something in lvalue.pm, which JSON::Path relies on. > > I've been playing at writing a replacement for lvalue.pm because lvalue.pm has other issues. (It's slower than it could be, plus there's a module on CPAN called Lvalue.pm which can cause problem on case-insensitive file systems - i.e. Windows.)
ok. Thanks for the reply, let me know if I can help (at least testing). -- Henri-Damien LAURENT FraudBuster Mail : henri-damien.laurent@fraudbuster.mobi Mobile : +33 6 88 77 62 53 Skype : laurenthdl
Here's my replacement for lvalue.pm. I shall port JSON::Path to it soon; I believe should solve the problem by avoiding creating an intermediate write-only value. https://metacpan.org/release/TOBYINK/LV-0.004
Patched in repo, and seems to work with Devel::ptkdb.
Fixed in 0.205.