Opened 10 years ago
Last modified 9 years ago
#659 new enhancement
mark_entry_failed should possibly rollback session
|Reported by:||Elrond||Owned by:|
|Cc:||Christopher Allan Webber||Parent Tickets:|
mark_entry_failed is often called after an exception.
This exception might be an sql exception (it shouldn't, but well, it happens). After an sql exception the session is in a broken state and mark_entry_failed can't do its job and mark the entry failed: If a session is broken, one can't use it for anything, until one cleans it up using
So the suggestion is to call
- If the session is clean: fine.
- If the session is broken: better clean it up instead of having a exception on an exception (harder to read).
- If someone missed to
.save()something, oh well, their fault.
Change History (1)
comment:1 by , 9 years ago
Doing this is nearly bitesized, IMHO.
I am tagging it.
it could be a big task to write a unit test for this. I don't know, if we want one?
If we want, please remove the bitesized tag!