X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=daklib%2Fchecks.py;h=436827372c9b9d27074b722ded838a1c1ac5de92;hb=1807bcb3ba6d31dfa058deaa6b7cbd3a3b1b6e8b;hp=b7931f2f6d8e60a2b893f6a304b357fe88cefd31;hpb=206fb80997ed8e3aa8ee317d454a3fb9470b7ffc;p=dak.git diff --git a/daklib/checks.py b/daklib/checks.py index b7931f2f..43682737 100644 --- a/daklib/checks.py +++ b/daklib/checks.py @@ -112,13 +112,11 @@ class SignatureAndHashesCheck(Check): def check_replay(self, upload): # Use private session as we want to remember having seen the .changes # in all cases. - session = DBConn().session() + session = upload.session history = SignatureHistory.from_signed_file(upload.changes) r = history.query(session) if r is not None: - raise Reject('Signature for changes file was already seen at {0}'.format(r.seen)) - session.add(history) - session.commit() + raise Reject('Signature for changes file was already seen at {0}.\nPlease refresh the signature of the changes file if you want to upload it again.'.format(r.seen)) return True """Check signature of changes and dsc file (if included in upload)