View Issue Details

IDProjectCategoryView StatusLast Update
0005503Talermechant backendpublic2019-12-20 19:12
ReporterChristian Grothoff Assigned ToChristian Grothoff  
PriorityurgentSeverityblockReproducibilityrandom
Status closedResolutionfixed 
Platformi7OSDebian GNU/LinuxOS Versionsqueeze
Product Versiongit (master) 
Target Version0.6Fixed in Version0.6 
Summary0005503: {'code': 2501, 'hint': 'db error: could not check for existing order'}
DescriptionA user reports:
This message appeared while paying for a chapter of Stallmans book:

{'code': 2501, 'hint': 'db error: could not check for existing order'}
Additional InformationThe 2501 error had 5 (!) different meanings, I've changed the code now to disambiguate them. That said, the "hint" narrows it down to just two cases, either a hard or a soft transaction failure when we ask the DB about the existing contract.

I'm not sure why the 'soft' error isn't retried, but it seems unlikely that we had a truly conflicting transaction given our current transaction rate and that Peter tried several times. My best guess right now is that we're missing a commit/rollback somewhere and thus everything is run as part of some 'ancient' transaction (and thus if we re-start the merchant, things will start to work again just until we get into that logic of the not properly terminated transaction).

Analysis shows that the _proposal.c logic of the merchant backend doesn't seem to properly deal with transactions (I see no begin/commit, but multiple SQL statements!), and also while there is a MAX_RETRIES the SOFT case is not retried. This may not explain this bug, but there is work to be done there!!!
TagsNo tags attached.

Activities

Christian Grothoff

2019-01-31 18:51

manager   ~0013539

Marcello is right (in his e-mail) that there is nothing more to be done here, in part because I actually did go over the file in the meantime, just forgot to 'resolve' this bug.

Issue History

Date Modified Username Field Change
2018-12-22 12:47 Christian Grothoff New Issue
2018-12-22 12:47 Christian Grothoff Status new => assigned
2018-12-22 12:47 Christian Grothoff Assigned To => Marcello Stanisci
2019-01-31 18:51 Christian Grothoff Assigned To Marcello Stanisci => Christian Grothoff
2019-01-31 18:51 Christian Grothoff Status assigned => resolved
2019-01-31 18:51 Christian Grothoff Resolution open => fixed
2019-01-31 18:51 Christian Grothoff Fixed in Version => 0.6
2019-01-31 18:51 Christian Grothoff Note Added: 0013539
2019-12-20 19:12 Christian Grothoff Status resolved => closed