Skip Menu |
 

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Workflow CPAN distribution.

Report information
The Basics
Id: 21099
Status: resolved
Priority: 0/
Queue: Workflow

People
Owner: jonasbn [...] cpan.org
Requestors: michael.bell [...] cms.hu-berlin.de
Cc:
AdminCc:

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



Subject: Wrong documentation of Condition configuration
Date: Mon, 21 Aug 2006 10:05:16 +0200
To: bug-Workflow [...] rt.cpan.org
From: Michael Bell <michael.bell [...] cms.hu-berlin.de>
Download smime.p7s
application/x-pkcs7-signature 7.7k

Message body not shown because it is not plain text.

Download (untitled) / with headers
text/plain 900b
Hi, Workflow 0.22 Perl 5.8.8 The documentation of the condition configuration contains a small bug. Conditions are checked by the module Workflow::State. This requires that the state configuration includes a reference to the condition. If the reference to the condition only exists in the full action specification (perhaps in a separate file) then the condition will be ignored. The issue is non-critical because only the documentation has a bug (nevertheless it costs some time to find the problem ;) ). Best regards Michael -- Show quoted text
_______________________________________________________________ Michael Bell Humboldt-Universitaet zu Berlin Tel.: +49 (0)30-2093 2482 ZE Computer- und Medienservice Fax: +49 (0)30-2093 2704 Unter den Linden 6 michael.bell@cms.hu-berlin.de D-10099 Berlin
_______________________________________________________________
Download Condition.pm.diff
text/x-diff 1.1k
--- Condition.pm.org 2006-08-21 09:51:43.000000000 +0200 +++ Condition.pm 2006-08-21 09:57:00.000000000 +0200 @@ -45,13 +45,17 @@ </condition> ... - # Reference the condition in an action... - <actions> - <action name="MyAction" class="My::Action"> - ... - <condition name="IsAdminUser" /> - </action> - ... + # Reference the condition in an action of the state/workflow definition... + <workflow> + <state> + ... + <action name="MyAction"> + ... + <condition name="IsAdminUser" /> + </action> + </state> + ... + </workflow> # Then implement the condition @@ -94,6 +98,13 @@ the available actions she might get a different answer than user B since they determine separate contexts. +B<NOTE>: The condition is enforced by Workflow::State. This means that +the condition name must be visible inside of the state definition. If +you specify the reference to the condition only inside of the full +action specification in a seperate file then nothing will happen. The +reference to the condition must be defined inside of the state/workflow +specification. + =head1 SUBCLASSING =head2 Strategy
Patch applied in release 0.23 jonasbn


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.