Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #75916 > unrolled thread

Re: Newbie needing some help

Started byChris Angelico <rosuav@gmail.com>
First post2014-08-09 09:38 +1000
Last post2014-08-09 09:38 +1000
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Newbie needing some help Chris Angelico <rosuav@gmail.com> - 2014-08-09 09:38 +1000

#75916 — Re: Newbie needing some help

FromChris Angelico <rosuav@gmail.com>
Date2014-08-09 09:38 +1000
SubjectRe: Newbie needing some help
Message-ID<mailman.12772.1407541107.18130.python-list@python.org>
On Sat, Aug 9, 2014 at 8:01 AM, Chris Kaynor <ckaynor@zindagigames.com> wrote:
> However, I'd recommend re-raising the exception after rolling back the
> transaction with a bare "raise" statement right after the db.rollback() - at
> the absolute minimum, you should log the error. This will likely let you see
> what your problem is.

AIUI, aborting the process with an uncaught exception would roll back
implicitly, so there's no need to "bare except, roll back, bare
raise". But even if that's not the case, I would be looking at a
try/finally for this, rather than a try/except/raise.

ChrisA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web