On patchwork.ozlabs.org, we see a lot of noise in the postgres logs, due
to INSERTs with duplicate values for (project,msgid) keys. Patchwork's
strategy for catching the resulting IntegrityError means that each of
these is logged.

Instead, this change moves to an atomic select -> insert for the Patch,
Comment and Coverletter parsing.

Jeremy Kerr (5):
  tests: Add duplicate mail test
  tests: ensure we don't see database errors during duplicate insert
  parser: prevent IntegrityErrors
  parser: don't trigger database IntegrityErrors on duplicate comments
  parser: don't trigger database IntegrityErrors on duplicate
    coverletters

 patchwork/parser.py            | 20 ++++++-----
 patchwork/tests/test_parser.py | 64 ++++++++++++++++++++++++++++++++++
 2 files changed, 75 insertions(+), 9 deletions(-)

-- 
2.17.1

_______________________________________________
Patchwork mailing list
Patchwork@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/patchwork

Reply via email to