On Dec 18, 2007, at 12:12 AM, Ben Bangert wrote:
In controllers, I think we can do away with the 'from ... import *'. While this works nicely for awhile, it almost always tends to leave a bad taste on people's mouth. The default controller template could instead come with the only necessary import:

Of course, those wanting to use 'from ... import *', no reason they can't continue to use that. ;)

I'm also looking at some of the locations for things, and since beaker handles its own stacked object proxy, I'm thinking it might be cleaner and less confusing if projects imported the session object from where the package that provides it... beaker. So instead of:

from pylons import session

When you want sessions, you'd add:
from beaker.middleware import beaker_session as session

The SessionMiddleware (that is imported and setup in middleware.py in 0.9.7) is already from Beaker, and this helps provide a clearer picture of the fact that your project is using these libraries.... thats it.

I'm just toying with this idea, so suggestions/input is welcome.

Cheers,
Ben

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to