Skip Menu |

This queue is for tickets about the MooseX-AttributeHelpers CPAN distribution.

Report information
The Basics
Id: 81564
Status: resolved
Priority: 0/
Queue: MooseX-AttributeHelpers

People
Owner: Nobody in particular
Requestors: ANDK [...] cpan.org
Cc: gregoa [...] cpan.org
AdminCc:

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



Subject: Test failures due to hash randomisation in perl 5.17.6
Since bleadperl v5.17.5-518-g7dc8663 your tests are failing frequently. That commit introduced hash key randomization and it seems at least the tests t/003_basic_hash.t t/203_trait_hash.t are hit by that. Find a sample fail report at: http://www.cpantesters.org/cpan/report/0f19d940-315d-11e2-83a5-eaa1a290f8f5 You can read more about the commit at http://perl5.git.perl.org/perl.git/commit/7dc8663964c66a698d31bbdc8e8abed69bddeec3 You may have to run the test several times until the randomization causes a fail. HTH&&Thanks&&Regards,
I'm not sure what to do this with this. This module is long-dead, having been absorbed into Moose ages ago. No new code should use it.
CC: ANDK [...] cpan.org
Subject: Re: [rt.cpan.org #81564] Test failures due to hash randomisation in perl 5.17.6
Date: Sun, 06 Jan 2013 23:00:32 +0100
To: bug-MooseX-AttributeHelpers [...] rt.cpan.org
From: Andreas Koenig <andreas.koenig.7os6VVqR [...] franz.ak.mind.de>
"Dave Rolsky via RT" <bug-MooseX-AttributeHelpers@rt.cpan.org> writes: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=81564 > > > I'm not sure what to do this with this. This module is long-dead, having > been absorbed into Moose ages ago. No new code should use it.
Maybe leave this ticket open forever so people can find this "last words" message of yours. Neither "resolve" nor "reject" would be appropriate here, I think. PAUSE also has a form where you can set it to abandoned, but this may be misunderstood and people would come and take it over, so it is probably not a good idea. I suppose you want to keep it on CPAN because old code is still around that uses it. Otherwise deletion from CPAN might help. -- andreas
Subject: Re: [rt.cpan.org #81564] Test failures due to hash randomisation in perl 5.17.6
Date: Sun, 6 Jan 2013 16:43:36 -0600 (CST)
To: "(Andreas J. Koenig) via RT" <bug-MooseX-AttributeHelpers [...] rt.cpan.org>
From: Dave Rolsky <autarch [...] urth.org>
On Sun, 6 Jan 2013, (Andreas J. Koenig) via RT wrote: Show quoted text
> Maybe leave this ticket open forever so people can find this "last > words" message of yours. Neither "resolve" nor "reject" would be > appropriate here, I think.
That seems fine. Show quoted text
> PAUSE also has a form where you can set it to abandoned, but this may be > misunderstood and people would come and take it over, so it is probably > not a good idea. > > I suppose you want to keep it on CPAN because old code is still around > that uses it. Otherwise deletion from CPAN might help.
Yeah, we don't want to delete it in case some other module or old code base uses it. The docs already tell you that it's deprecated. -dave /*============================================================ http://VegGuide.org http://blog.urth.org Your guide to all that's veg House Absolute(ly Pointless) ============================================================*/
Looking at the long list in https://metacpan.org/requires/distribution/MooseX-AttributeHelpers I wonder if there should be some solution here? E.g. providing active migration help for all these distributions, or maybe fixing the problematic test? Regards, Slaven
Subject: Re: [rt.cpan.org #81564] Test failures due to hash randomisation in perl 5.17.6
Date: Tue, 2 Jul 2013 10:39:44 -0700
To: Slaven_Rezic via RT <bug-MooseX-AttributeHelpers [...] rt.cpan.org>
From: Karen Etheridge <ether [...] cpan.org>
On Tue, Jul 02, 2013 at 06:25:06AM -0400, Slaven_Rezic via RT wrote: Show quoted text
> Looking at the long list in https://metacpan.org/requires/distribution/MooseX-AttributeHelpers I wonder if there should be some solution here? E.g. providing active migration help for all these distributions, or maybe fixing the problematic test?
I think it's reasonable to stand by leaving the test broken, as extra incentive to move off of deprecated (and now, known-to-be-buggy) code. I have created tickets on all dists that have been released in the last year (a total of eight); those using RT as their tracker are linked in this bug under 'referred to by'. Migrating is pretty straight-forward, given the documentation in Moose under 'native attribute traits'. We can also assist if anyone steps forward with any questions.
From: ppisar [...] redhat.com
Dne Pá 30.lis.2012 00:21:29, ANDK napsal(a): Show quoted text
> Since bleadperl v5.17.5-518-g7dc8663 your tests are failing > frequently. > That commit introduced hash key randomization and it seems at least > the > tests > > t/003_basic_hash.t > t/203_trait_hash.t >
For those who are need a fix, here it is attached. -- Petr
Subject: MooseX-AttributeHelpers-0.23-Fix-tests-to-cope-radnomized-hash-keys.patch
From 94d4ecede542aa0ae5e33e1aa68c6d9731bf295e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com> Date: Fri, 2 Aug 2013 19:09:45 +0200 Subject: [PATCH] Fix tests to cope radnomized hash keys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Similar patch is in Moose. <https://rt.cpan.org/Public/Bug/Display.html?id=81564> Signed-off-by: Petr Písař <ppisar@redhat.com> --- t/003_basic_hash.t | 4 ++-- t/203_trait_hash.t | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/t/003_basic_hash.t b/t/003_basic_hash.t index 1f842ae..c21ac52 100644 --- a/t/003_basic_hash.t +++ b/t/003_basic_hash.t @@ -170,10 +170,10 @@ is_deeply($options->provides, { is($options->type_constraint->type_parameter, 'Str', '... got the right container type'); $stuff->set_option( oink => "blah", xxy => "flop" ); -my @key_value = $stuff->key_value; +my @key_value = sort{ $a->[0] cmp $b->[0] } $stuff->key_value; is_deeply( \@key_value, - [ [ 'xxy', 'flop' ], [ 'quantity', 4 ], [ 'oink', 'blah' ] ], + [ sort{ $a->[0] cmp $b->[0] } [ 'xxy', 'flop' ], [ 'quantity', 4 ], [ 'oink', 'blah' ] ], '... got the right key value pairs' ); diff --git a/t/203_trait_hash.t b/t/203_trait_hash.t index 8e876b1..451c0bb 100644 --- a/t/203_trait_hash.t +++ b/t/203_trait_hash.t @@ -156,10 +156,10 @@ is_deeply($options->provides, { is($options->type_constraint->type_parameter, 'Str', '... got the right container type'); $stuff->set_option( oink => "blah", xxy => "flop" ); -my @key_value = $stuff->key_value; +my @key_value = sort{ $a->[0] cmp $b->[0] } $stuff->key_value; is_deeply( \@key_value, - [ [ 'xxy', 'flop' ], [ 'quantity', 4 ], [ 'oink', 'blah' ] ], + [ sort{ $a->[0] cmp $b->[0] } [ 'xxy', 'flop' ], [ 'quantity', 4 ], [ 'oink', 'blah' ] ], '... got the right key value pairs' ); -- 1.8.1.4
I just tried to install Chart::Clicker under 5.18.1, but that failed because somewhere down in the dependencies is Forest, which depends on MooseX-AttributeHelpers.
CC: ;
Subject: Re: [rt.cpan.org #81564] Test failures due to hash randomisation in perl 5.17.6
Date: Tue, 17 Dec 2013 16:54:40 -0500
To: Neil_Bowers via RT <bug-MooseX-AttributeHelpers [...] rt.cpan.org>
From: Jesse Luehrs <doy [...] tozt.net>
On Tue, Dec 17, 2013 at 04:27:12PM -0500, Neil_Bowers via RT wrote: Show quoted text
> Queue: MooseX-AttributeHelpers > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=81564 > > > I just tried to install Chart::Clicker under 5.18.1, but that failed > because somewhere down in the dependencies is Forest, which depends on > MooseX-AttributeHelpers.
I just submitted https://github.com/stevan/forest/pull/1, hopefully stevan can get around to releasing it soon. -doy
Subject: Re: [rt.cpan.org #81564] Test failures due to hash randomisation in perl 5.17.6
Date: Tue, 17 Dec 2013 16:45:50 -0600 (CST)
To: Neil_Bowers via RT <bug-MooseX-AttributeHelpers [...] rt.cpan.org>
From: Dave Rolsky <autarch [...] urth.org>
On Tue, 17 Dec 2013, Neil_Bowers via RT wrote: Show quoted text
> Queue: MooseX-AttributeHelpers > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=81564 > > > I just tried to install Chart::Clicker under 5.18.1, but that failed because somewhere down in the dependencies is Forest, which depends on MooseX-AttributeHelpers.
MX::AH is long deprecated. Modules should be using the native traits feature built into Moose itself. -dave /*============================================================ http://VegGuide.org http://blog.urth.org Your guide to all that's veg House Absolute(ly Pointless) ============================================================*/
RT-Send-CC: doy [...] tozt.net
Show quoted text
> I just submitted https://github.com/stevan/forest/pull/1, hopefully > stevan can get around to releasing it soon.
Thanks DOY, I've noticed a new release of Forest is making its way round CPAN -- I'll have another go tonight. Cheers, Neil
RT-Send-CC: autarch [...] urth.org
I know this distribution is deprecated, but it would still be helpful to fix this, as it's pulled in as a develop prereq of Pod::Coverage::Moose (there is an optional test that checks MXAH compatibility). If you push the repo to github I'll be happy to take care of it (with or without comaint).
Fixed in version 0.24!