On Fri, Jun 13, 2008 at 01:37:33PM +0200, Tomeu Vizoso wrote: > + cur = self._con.cursor() > ... > + cur.close() > > Should we use try...finally blocks so we don't leak open cursors? > Also, we could use the with statement from future.
The "with" statement (and the contextlib's @contextmanager decorator) have worked out really well for me so far. I'd be happy to see it used more widely throughout Sugar. Michael _______________________________________________ Sugar mailing list Sugar@lists.laptop.org http://lists.laptop.org/listinfo/sugar