[Catalyst] default : Local v. default : Path
Tomas Doran
bobtfish at bobtfish.net
Mon Jul 6 20:51:44 GMT 2009
On 6 Jul 2009, at 18:14, Paul Makepeace wrote:
> We just upgraded from 5.80005 to 5.80007 and default : Local is no
> longer matching $controller/ (i.e. requires $controller/default)
>
> I was curious what the difference is, and flagging it for anyone else.
Yes, sorry about that - it's a regression / correctness fix. 5.80005
considered anything called 'default' to be a default method, no
matter what attributes you have it - which was a huge pile of fail..
The incorrect behavior was:
sub default : Chained('/') PathPart('foobarbaz') Args(0) => became /
mycontrollernamespace/.*
The correct behavior is:
sub default : Local => asking for mycontrollernamespace/default
sub default : Private => asking to be last-case fallback for
mycontrollernamespace/.*
This is somewhat a regression on 5.7, and somewhat a fix - as we now
correctly handle priorities in all cases with default / Path actions,
allowing the most specific action to match in all cases.
> FWIW, IMO, http://search.cpan.org/~hkclark/Catalyst-Manual-5.8000/
> lib/Catalyst/Manual/Intro.pod#Built-in_special_actions is a
> slightly odd place to be documenting in reference style the
> actions. Is there another place? This is one of those things I keep
> expecting has a home and then eventually finding back in the
> Manual's intro.
I totally agree. Please nominate where it should be (where did you
look hardest that it wasn't), and we'll put it there instead, with
the clarifications to the expected behavior you're about to make if
it isn't crystal as-is.. :)
Cheers
t0m
More information about the Catalyst
mailing list