Re: Bad form to access a *private variable* like _foo?

Top Page

Reply to this message
Author: Diez B. Roggisch
Date:  
To: python-list
Subject: Re: Bad form to access a *private variable* like _foo?
> The way you wrote it here, yes. If there's no official way to do the
> same operation and you have a real use case for it - in which case you
> may want to add a commit() method to SQLObject's model base class and
> submit the patch to SQLObject's maintainer. But I strongly suspect
> there's a better way to handle this case in SQLObject's API.


There are other ways. For example,

sqlobject.sqlhub.threadingLocal.connection

if your system is using multiple threads correctly. Generally speaking,
sqlhub could/should be used.


Diez
--
http://mail.python.org/mailman/listinfo/python-list