Skip Menu |

This queue is for tickets about the CGI-Application-Plugin-ValidateRM CPAN distribution.

Report information
The Basics
Id: 35056
Status: resolved
Priority: 0/
Queue: CGI-Application-Plugin-ValidateRM

People
Owner: MARKSTOS [...] cpan.org
Requestors: zakame [...] cpan.org
Cc:
AdminCc:

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



Subject: test failure at t/forward.t #2 'form is returned'
Install failure on CGI-Application-Plugin-ValidateRM-2.1, installing to a perl-5.8.8 (darwin-thread-multi-2level) on a Darwin alteran.local 8.11.1 Darwin Kernel Version 8.11.1: Wed Oct 10 18:23:28 PDT 2007; root:xnu-792.25.20~1/RELEASE_I386 i386 i386. make test TEST_VERBOSE=1: alteran:~/.cpan/build/CGI-Application-Plugin-ValidateRM-2.1-m_nrKE zakame$ make test TEST_VERBOSE=1 PERL_DL_NONLAZY=1 /opt/local/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(1, 'blib/lib', 'blib/arch')" t/*.t t/01_basic...... 1..14 ok 1 - use CGI::Application::Plugin::ValidateRM; ok 2 - err__ ok 3 - basic invalid ok 4 - basic missing ok 5 - err__ ok 6 - basic invalid ok 7 - basic missing ok 8 - t3 basic missing ok 9 - passing options to HTML::FillInForm works ok 10 - has dfv_results method ok 11 - has dfv_error_page method ok 12 - has check_rm_error_page method ok 13 - content of DFV method is as expected ok 14 - calling check_rm in scalar context returns just the DFV obj. ok t/99_pod........ 1..1 ok 1 - POD test for blib/lib/CGI/Application/Plugin/ValidateRM.pm ok t/forward....... 1..4 ok 1 - if # ::Forward is not loaded, current_rm is not updated not ok 2 - form is returned # Failed test 'form is returned' # at t/forward.t line 22. # got: 'legacy form output HUH' # expected: 'legacy form output' ok 3 # SKIP CGI::Application::Plugin::Forward required ok 4 # SKIP CGI::Application::Plugin::Forward required # Looks like you failed 1 test of 4. Dubious, test returned 1 (wstat 256, 0x100) Failed 1/4 subtests (less 2 skipped subtests: 1 okay) Test Summary Report ------------------- t/forward.t (Wstat: 256 Tests: 4 Failed: 1) Failed test: 2 Non-zero exit status: 1 Files=3, Tests=19, 1 wallclock secs ( 0.02 usr 0.01 sys + 0.30 cusr 0.09 csys = 0.42 CPU) Result: FAIL Failed 1/3 test programs. 1/19 subtests failed. make: *** [test_dynamic] Error 1 Checking against cpantesters: cpan[10]> reports MARKSTOS/CGI-Application-Plugin-ValidateRM-2.1.tar.gz Distribution: M/MA/MARKSTOS/CGI-Application-Plugin-ValidateRM-2.1.tar.gz Fetching 'http://cpantesters.perl.org/show/CGI-Application-Plugin-ValidateRM.yaml'...DONE 2.1: +PASS 5.8.5 on Linux 2.6.3-25mdk-i686-up-4gb (i386-linux-thread-multi) -FAIL 5.8.7 on Linux 2.4.30 (i686-linux-thread-multi-64int-ld) +PASS 5.8.5 on Solaris 2.9 (sun4-solaris-thread-multi) +PASS 5.8.5 on MSWin32 4.0 (MSWin32-x86-multi-thread) +PASS 5.8.7 on Linux 2.6.9-22.el (i686-linux) +PASS 5.8.8 on Linux 2.6.16.14 (x86_64-linux-thread-multi-ld) +PASS 5.8.8 on Linux 2.4.20-8smp (i686-linux) -FAIL 5.9.5 on Darwin 8.10.1 (darwin-2level) -FAIL 5.10.0 on Linux 2.6.22.10 (x86_64-linux-thread-multi-ld) +PASS 5.8.4 on Linux 2.4.26 (i486-linux) See http://cpantesters.perl.org/show/CGI-Application-Plugin-ValidateRM.html for details This is also the case in my other machine running perl-5.10.0 on i686-linux.
From: MARKSTOS [...] cpan.org
Zakame, Could you also supply a patch to fix the issue? Otherwise, I'll to get eventually. Mark On Tue Apr 15 03:32:08 2008, ZAKAME wrote: Show quoted text
> Install failure on CGI-Application-Plugin-ValidateRM-2.1, installing > to > a perl-5.8.8 (darwin-thread-multi-2level) on a Darwin alteran.local > 8.11.1 Darwin Kernel Version 8.11.1: Wed Oct 10 18:23:28 PDT 2007; > root:xnu-792.25.20~1/RELEASE_I386 i386 i386. > > make test TEST_VERBOSE=1: > > alteran:~/.cpan/build/CGI-Application-Plugin-ValidateRM-2.1-m_nrKE > zakame$ make test TEST_VERBOSE=1 > PERL_DL_NONLAZY=1 /opt/local/bin/perl "-MExtUtils::Command::MM" "-e" > "test_harness(1, 'blib/lib', 'blib/arch')" t/*.t > t/01_basic...... > 1..14 > ok 1 - use CGI::Application::Plugin::ValidateRM; > ok 2 - err__ > ok 3 - basic invalid > ok 4 - basic missing > ok 5 - err__ > ok 6 - basic invalid > ok 7 - basic missing > ok 8 - t3 basic missing > ok 9 - passing options to HTML::FillInForm works > ok 10 - has dfv_results method > ok 11 - has dfv_error_page method > ok 12 - has check_rm_error_page method > ok 13 - content of DFV method is as expected > ok 14 - calling check_rm in scalar context returns just the DFV obj. > ok > t/99_pod........ > 1..1 > ok 1 - POD test for blib/lib/CGI/Application/Plugin/ValidateRM.pm > ok > t/forward....... > 1..4 > ok 1 - if > # ::Forward is not loaded, current_rm is not updated > not ok 2 - form is returned > > # Failed test 'form is returned' > # at t/forward.t line 22. > # got: 'legacy form output HUH' > # expected: 'legacy form output' > ok 3 # SKIP CGI::Application::Plugin::Forward required > ok 4 # SKIP CGI::Application::Plugin::Forward required > # Looks like you failed 1 test of 4. > Dubious, test returned 1 (wstat 256, 0x100) > Failed 1/4 subtests > (less 2 skipped subtests: 1 okay) > > Test Summary Report > ------------------- > t/forward.t (Wstat: 256 Tests: 4 Failed: 1) > Failed test: 2 > Non-zero exit status: 1 > Files=3, Tests=19, 1 wallclock secs ( 0.02 usr 0.01 sys + 0.30 cusr > 0.09 csys = 0.42 CPU) > Result: FAIL > Failed 1/3 test programs. 1/19 subtests failed. > make: *** [test_dynamic] Error 1 > > Checking against cpantesters: > > cpan[10]> reports MARKSTOS/CGI-Application-Plugin-ValidateRM- > 2.1.tar.gz > Distribution: M/MA/MARKSTOS/CGI-Application-Plugin-ValidateRM- > 2.1.tar.gz > Fetching > 'http://cpantesters.perl.org/show/CGI-Application-Plugin- > ValidateRM.yaml'...DONE > > 2.1: > +PASS 5.8.5 on Linux 2.6.3-25mdk-i686-up-4gb (i386-linux-thread- > multi) > -FAIL 5.8.7 on Linux 2.4.30 (i686-linux-thread-multi-64int-ld) > +PASS 5.8.5 on Solaris 2.9 (sun4-solaris-thread-multi) > +PASS 5.8.5 on MSWin32 4.0 (MSWin32-x86-multi-thread) > +PASS 5.8.7 on Linux 2.6.9-22.el (i686-linux) > +PASS 5.8.8 on Linux 2.6.16.14 (x86_64-linux-thread-multi-ld) > +PASS 5.8.8 on Linux 2.4.20-8smp (i686-linux) > -FAIL 5.9.5 on Darwin 8.10.1 (darwin-2level) > -FAIL 5.10.0 on Linux 2.6.22.10 (x86_64-linux-thread-multi-ld) > +PASS 5.8.4 on Linux 2.4.26 (i486-linux) > See > http://cpantesters.perl.org/show/CGI-Application-Plugin- > ValidateRM.html > for details > > > This is also the case in my other machine running perl-5.10.0 on i686- > linux.
Subject: Re: [rt.cpan.org #35056] test failure at t/forward.t #2 'form is returned'
Date: Wed, 16 Apr 2008 08:54:25 +0800
To: bug-CGI-Application-Plugin-ValidateRM [...] rt.cpan.org
From: "Zak B. Elep" <zakame [...] cpan.org>
On 4/15/08, MARKSTOS via RT <bug-CGI-Application-Plugin-ValidateRM@rt.cpan.org> wrote: Show quoted text
> Could you also supply a patch to fix the issue? Otherwise, I'll to get > eventually.
I'll try. ;) Is the 'HUH' part of the *_form runmodes in the tests supposed to be removed somewhere during the process, before the Test::More::is() checks? I don't really see any code in the ValidateRM plugin itself doing this, neither in Data::FormValidator nor HTML::FillInForm... Cheers, Zakame -- Zak B. Elep || http://zakame.spunge.org zakame@ubuntu.com || zakame@spunge.org || zakame@morphlabs.com 1486 7957 454D E529 E4F1 F75E 5787 B1FD FA53 851D
On Tue Apr 15 20:54:44 2008, ZAKAME wrote: Show quoted text
> Is the 'HUH' part of the *_form runmodes in the tests supposed to be > removed somewhere during the process, before the Test::More::is() > checks? I don't really see any code in the ValidateRM plugin itself > doing this, neither in Data::FormValidator nor HTML::FillInForm...
Here is a patch that just removes that 'HUH' in the forward test; I don't really know if it is the correct patch as I don't see a reason why there is that 'HUH' in the test. This perplexes me as I see test PASSes on other platforms, so I'm probably missing something.
From f71667ad5b7708545876fd75496a5b36541aa3b0 Mon Sep 17 00:00:00 2001 From: Zak B. Elep <zakame@cpan.org> Date: Wed, 16 Apr 2008 08:57:06 +0800 Subject: [PATCH] Remove extraneous HUH in forward test The forward test fails due to an extra 'HUH' string returned by the *_form runmodes; I don't really know whether if this should be removed by something else during the check_rm() process, since I don't see any code elsewhere (even outside ValidateRM) that removes the string. Signed-off-by: Zak B. Elep <zakame@cpan.org> --- t/forward.t | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/t/forward.t b/t/forward.t index 87e829d..fe80c14 100644 --- a/t/forward.t +++ b/t/forward.t @@ -12,7 +12,7 @@ $ENV{CGI_APP_RETURN_ONLY} = 1; sub legacy_form { my $self = shift; Test::More::is($self->get_current_runmode, 'legacy_process', "if ::Forward is not loaded, current_rm is not updated"); - $self->header_type('none'); return "legacy form output HUH"; } + $self->header_type('none'); return "legacy form output"; } sub legacy_process { my $self = shift; my ($results, $err_page) = $self->check_rm('legacy_form', { required => 'fail' }); return @@ -42,7 +42,7 @@ SKIP: { Test::More::is($self->get_current_runmode, 'forward_form', "if ::Forward is loaded, current_rm is updated"); $self->header_type('none'); - return "forward form output HUH"; + return "forward form output"; } sub forward_process { -- 1.5.4.5
Subject: Re: [rt.cpan.org #35056] test failure at t/forward.t #2 'form is returned'
Date: Wed, 16 Apr 2008 10:19:05 -0400
To: bug-CGI-Application-Plugin-ValidateRM [...] rt.cpan.org
From: Mark Stosberg <mark [...] summersault.com>
Zak B. Elep via RT wrote: Show quoted text
> Queue: CGI-Application-Plugin-ValidateRM > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=35056 > > > On Tue Apr 15 20:54:44 2008, ZAKAME wrote:
>> Is the 'HUH' part of the *_form runmodes in the tests supposed to be >> removed somewhere during the process, before the Test::More::is() >> checks? I don't really see any code in the ValidateRM plugin itself >> doing this, neither in Data::FormValidator nor HTML::FillInForm...
> > Here is a patch that just removes that 'HUH' in the forward test; I > don't really know if it is the correct patch as I don't see a reason why > there is that 'HUH' in the test. This perplexes me as I see test PASSes > on other platforms, so I'm probably missing something.
Zak, Thanks for trying. This bug appeared somewhat recently without any code changes in ValidateRM. You can see through the search.cpan.org page for the module that all the tests generally pass for most people. What I suspect then is that the problem is with a different version of an external module, like DFV, HTML::FillInForm or CGI.pm. I suspect our "fix" may be to explicitly require a later version of one of these modules, but first we have to understand why the test only fails someone. I fear that if we just update the test to pass in this case, it may only mean that it starts to fail for people it currently passes for. Your help is appreciated! Mark
On Wed Apr 16 10:20:35 2008, mark@summersault.com wrote: Show quoted text
> Thanks for trying. This bug appeared somewhat recently without any code > changes in ValidateRM. You can see through the search.cpan.org page for > the module that all the tests generally pass for most people.
Yep, the cpantesters page for this indicates the module passes for a lot of installations, so there could be something else beyond the module's code that's triggering this bug Show quoted text
> What I suspect then is that the problem is with a different version of > an external module, like DFV, HTML::FillInForm or CGI.pm. > > I suspect our "fix" may be to explicitly require a later version of one > of these modules, but first we have to understand why the test only > fails someone.
Anything I can do to help here? Show quoted text
> I fear that if we just update the test to pass in this case, it may only > mean that it starts to fail for people it currently passes for. > > Your help is appreciated!
Thanks! Yep, that's what I feared too, as I felt changing the test itself was a bit of a cheat working around the actual bug. Cheers, Zakame
From 'Changes' of HTML::FillInForm 1.07: "Fix a bug the last plaintext part might be chopped if called via scalarref [rt.cpan.org #21750] (Tatsuhiko Miyagawa)" Only 1 FAIL and 2 PASS has dependencies versions listed. FAIL - HTML::FillInForm 1.06 PASS - HTML::FillInForm 2.00 It seems that putting 1.07 in dependencies and removing 'HUH' is correct solution. -- Alexandr Ciornii, http://chorny.net
I have attempted to address this by just uploaded 2.2, which requires HTML::FillInForm 1.07. Let's see if that fixes it. Mark
Subject: Re: [rt.cpan.org #35056] test failure at t/forward.t #2 'form is returned'
Date: Tue, 6 May 2008 10:21:33 -0400
To: bug-CGI-Application-Plugin-ValidateRM [...] rt.cpan.org
From: Mark Stosberg <mark [...] summersault.com>
Show quoted text
> >From 'Changes' of HTML::FillInForm 1.07: "Fix a bug the last plaintext
> part might be chopped if called via scalarref [rt.cpan.org #21750] > (Tatsuhiko Miyagawa)" > > Only 1 FAIL and 2 PASS has dependencies versions listed. > FAIL - HTML::FillInForm 1.06 > PASS - HTML::FillInForm 2.00 > > It seems that putting 1.07 in dependencies and removing 'HUH' is correct > solution.
I tried this approach for the 2.2 release, and it didn't work. In fact, tests are failing everywhere now: http://cpantesters.perl.org/show/CGI-Application-Plugin-ValidateRM.html There must be some other dependency in the chain that changed its behavior... maybe CGI.pm? It still needs further investigation. Mark
I see what part of the issue is. In my development environment, I was getting a reverse result. An incorrect setup pass, while a correct one would fail. This was with FreeBSD 6.1 and Perl 5.8.0. I suspect this older version of Perl may be somehow at fault, although I don't understand why. I've just gotten the failing test to pass on Linux with Perl 5.8.8, and will upload a revised version soon. Makr
Subject: test failure at t/forward.t #2 'form is returned' (fix released)
I released a new version to address this.