Skip Menu |

This queue is for tickets about the DBIx-Class-QueryProfiler CPAN distribution.

Report information
The Basics
Id: 88759
Status: new
Priority: 0/
Queue: DBIx-Class-QueryProfiler

People
Owner: Nobody in particular
Requestors: mzrinsky [...] redanvil.net
Cc:
AdminCc:

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



Subject: Wrong caller in latest DBIx::Class
In the latest DBIx::Class (0.08250) it is using Context::Preserve, which messes up the caller that gets printed in the print method of DBIx::Class::QueryProfiler. Attached a patch which adds Context::Preserve to the list of classes to skip, when looking for the caller. Also, thank you for this module, it is really nice and very helpful. :)
Subject: dbix_query_profiler_caller.patch
--- DBIx/Class/QueryProfiler.pm 2013-09-17 22:14:36.806733055 -0500 +++ /tmp/DBIx/Class/QueryProfiler.pm 2013-09-17 22:17:43.190953120 -0500 @@ -124,7 +124,7 @@ my $i = 0; my @c; while (@c = caller(++$i)) { - next if $c[0] =~ m{^(?:DBIx::Class|Catalyst|Class::MOP|Moose::Object)}; + next if $c[0] =~ m{^(?:DBIx::Class|Catalyst|Class::MOP|Moose::Object|Context::Preserve)}; next if exists $Carp::Internal{$c[0]}; last; }