[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread jorge.vargas
On Wed, Feb 11, 2009 at 11:28 AM, Gustavo Narea m...@gustavonarea.net wrote: Hello, everybody. I already mentioned this in another email, but I think it deserves its own thread. In trunk I've implemented a class decorator that sets controller-wide access rules (@tg.protect), based on the

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread Gustavo Narea
On Wednesday February 11, 2009 16:49:13 jorge.vargas wrote: class decorators? what about everyone not in py2.6? I think way back when allow_only was created we agreed it was a good compromise before class decorators where introduced. class DaController(BaseController): pass DaController =

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread jorge.vargas
On Wed, Feb 11, 2009 at 12:00 PM, Gustavo Narea m...@gustavonarea.net wrote: On Wednesday February 11, 2009 16:49:13 jorge.vargas wrote: class decorators? what about everyone not in py2.6? I think way back when allow_only was created we agreed it was a good compromise before class decorators

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread Gustavo Narea
On Wednesday February 11, 2009 17:13:12 jorge.vargas wrote: I think at this point this will confuse people more than what it will help, why didn't you suggested this way back when allow_only was introduced? 1.- That feature existed even before I joined TurboGears, as Controller.require.

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread jorge.vargas
On Wed, Feb 11, 2009 at 12:24 PM, Gustavo Narea m...@gustavonarea.net wrote: On Wednesday February 11, 2009 17:13:12 jorge.vargas wrote: I think at this point this will confuse people more than what it will help, why didn't you suggested this way back when allow_only was introduced? 1.-

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread Florent Aide
On Wed, Feb 11, 2009 at 5:35 PM, jorge.vargas jorge.var...@gmail.com wrote: I like the class decorator approach but I'm really not sure if it will break stuff already build on TG. It doesn't break anything by itself, but I'm proposing that we drop the Controller.allow_only feature. it

[tg-trunk] Re: Let's replace Controller.allow_only with @protect

2009-02-11 Thread jorge.vargas
On Wed, Feb 11, 2009 at 12:57 PM, Florent Aide florent.a...@gmail.com wrote: On Wed, Feb 11, 2009 at 5:35 PM, jorge.vargas jorge.var...@gmail.com wrote: I like the class decorator approach but I'm really not sure if it will break stuff already build on TG. It doesn't break anything by