On Thu, Dec 18, 2008 at 4:44 PM, Jonathan Vanasco <jonat...@findmeon.com> wrote: > I can't seem to reply to the 'group', so i'm emailing the group > address and 2 vocal people, hoping for the best. apologies if you get > this 2x. > > something that i would LOVE to see in routes, is this: > > right now, routes maps like this: > > map.connect( 'faq_page', 'faq', controller='semi_static', > action='faq') > > for: > file - controllers/semi_static.py > controller - SemiStaticController > method - faq > > what i'd love is the ability to do something like this > > map.connect( 'faq_page', 'faq', controller='SemiStatic_Controller', > action='faq') > > see, i hate the automagic mapping of semi_static to > SemiStatic_Controller... i could get into a long argument about > semantics, but i'll save us from boredom. i just think that if routes > were to operate the same way, but also allow explicit controller > naming ( identified by _Controller as the suffix ), it would totally > rock.
Received. There's also a problem with not being able to specify the case of the controller, which can lead to monstrosities like MyxmlController or SqlalchemyController, which can be hard to read if you don't know the acronym ends and the adjacent word begins. I'm not sure what the most robust solution is, as you have to imply both the module name and class name, and it needs to work with modules in subpackages too. "_Controller" is too unobvious as a suffix. Maybe a symbol prefix like "#". But in that case we might want to kill two birds with one stone and do "#package.module:ClassController", using an entry point-like syntax for consistency. -- Mike Orr <sluggos...@gmail.com> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to pylons-discuss@googlegroups.com To unsubscribe from this group, send email to pylons-discuss+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---