[Catalyst] Quesion about Chaining usage

Matt S Trout dbix-class at trout.me.uk
Tue Sep 5 18:34:18 CEST 2006

John Napiorkowski wrote:
> I've already tried both /feedrolls and /feedrolls/
> just to see.  I've also tried changing the action
> names around just in case there was something in the
> code that would confuse similarly named subs, but that
> didn't do it.
> I'm starting to get the feeling there is something
> going on with PathPart being set to ''.  This code
> works fine if I set the feedroll action to Args(1) and
> then forward to feedroll_all like I used to do before
> I had chaining.
> Let me work up an example that is not dependent on my
> data model, maybe someone can try running it on their
> setup and see what happens.  I definitely would not
> rule up something borked on my side, although I did
> just run an updater for all my installed Catalyst
> modules.
> I also reran all the chaining tests I could find and
> didn't get an error.
> I find that if I alter line 115 of my code example to
> have a pathpart (I remove the PathPart('') so it goes
> to the default of using the action name) then I also
> get it to work.  So there is something strange going
> on when you set too many pathparts to '', which is
> probably an abuse of the system on my part :)

Possibly, but I abuse it at least that much in some of my code and it survives 
it. You might want to see if you can re-create it as a patch to the tests for 
Chained (there are quite a lot of them now thanks to phaylon and others), or 
to look at the tests for Chained as possible inspiration for finding a mistake 
neither of us have spotted.

I look forward to either an e-mail going "yay!" or a test patch so I can fix 
this up :)

      Matt S Trout       Offering custom development, consultancy and support
   Technical Director    contracts for Catalyst, DBIx::Class and BAST. Contact
Shadowcat Systems Ltd.  mst (at) shadowcatsystems.co.uk for more information

+ Help us build a better perl ORM: http://dbix-class.shadowcatsystems.co.uk/ +

More information about the Catalyst mailing list