View Issue Details

IDProjectCategoryView StatusLast Update
0004822Talerobsolete componentpublic2017-06-06 14:18
ReporterFlorian Dold Assigned ToMarcello Stanisci  
PriorityhighSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Versiongit (master) 
Target Version0.3Fixed in Version0.3 
Summary0004822: bank does not run financial transactions in database transactions
Description... django requires decorators for that.
TagsNo tags attached.

Activities

Marcello Stanisci

2016-11-29 00:45

reporter   ~0011551

Florian, can you elaborate a bit more on that?

Florian Dold

2016-11-29 00:49

manager   ~0011552

Sure, see: https://docs.djangoproject.com/en/1.10/topics/db/transactions/#autocommit-details

When we do a wire transfer, we of course have to touch multiple accounts. But these write operations are currently not run within a DB transaction, due to Django's autocommit behavior.

Marcello Stanisci

2016-12-22 17:10

reporter   ~0011608

Shall I wait your refactoring to be complete to work on this one?

Marcello Stanisci

2017-01-31 14:59

reporter   ~0011682

From [1], it seems that no decorators are needed. Just setting your DB as "atomic" should make it.

[1] https://docs.djangoproject.com/en/1.9/topics/db/transactions/#tying-transactions-to-http-requests

Marcello Stanisci

2017-01-31 15:03

reporter   ~0011683

OTOH, [2] is better, as you're not forced to be in a view to have transactions.

[2] https://docs.djangoproject.com/en/1.9/topics/db/transactions/#controlling-transactions-explicitly

Marcello Stanisci

2017-02-04 10:54

reporter   ~0011689

According to the recent refactoring, there might be few or no places
where this fix should be done.

Marcello Stanisci

2017-02-06 21:36

reporter   ~0011699

3ae843c. The fix occurred at user registration and in wire_transfer().

Issue History

Date Modified Username Field Change
2016-11-29 00:39 Florian Dold New Issue
2016-11-29 00:39 Florian Dold Status new => assigned
2016-11-29 00:39 Florian Dold Assigned To => Marcello Stanisci
2016-11-29 00:45 Marcello Stanisci Note Added: 0011551
2016-11-29 00:49 Florian Dold Note Added: 0011552
2016-12-22 17:10 Marcello Stanisci Note Added: 0011608
2017-01-31 14:59 Marcello Stanisci Note Added: 0011682
2017-01-31 15:03 Marcello Stanisci Note Added: 0011683
2017-02-04 10:54 Marcello Stanisci Priority normal => high
2017-02-04 10:54 Marcello Stanisci Note Added: 0011689
2017-02-06 21:36 Marcello Stanisci Status assigned => resolved
2017-02-06 21:36 Marcello Stanisci Resolution open => fixed
2017-02-06 21:36 Marcello Stanisci Note Added: 0011699
2017-02-13 13:46 Christian Grothoff Product Version => git (master)
2017-02-13 13:46 Christian Grothoff Fixed in Version => 0.3
2017-02-13 13:46 Christian Grothoff Target Version => 0.3
2017-06-06 14:18 Christian Grothoff Status resolved => closed
2022-08-23 20:26 Christian Grothoff Category bank (demonstrator) => py bank (demonstrator, obsolete)
2023-12-03 01:23 Christian Grothoff Category py bank (demonstrator, obsolete) => obsolete componet
2023-12-11 20:08 Florian Dold Category obsolete componet => obsolete component