X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=sidebyside;f=dak%2Fprocess_upload.py;h=64c8c58b239529a3386bcfd6b12b4789c5f74b17;hb=48caaad6d88090e3a3ac85e2dc892d6f3a8ef630;hp=bf5cda591d210c71ef735999b0a2643e11a04134;hpb=1e945c24f59d3e92ef18f456b60aa10210a3113c;p=dak.git diff --git a/dak/process_upload.py b/dak/process_upload.py index bf5cda59..64c8c58b 100755 --- a/dak/process_upload.py +++ b/dak/process_upload.py @@ -212,7 +212,7 @@ def try_or_reject(function): try: return function(directory, upload, *args, **kwargs) except (daklib.archive.ArchiveException, daklib.checks.Reject) as e: - reason = e + reason = unicode(e) except Exception as e: reason = "There was an uncaught exception when processing your upload:\n{0}\nAny original reject reason follows below.".format(traceback.format_exc()) @@ -251,6 +251,8 @@ def get_processed_upload(upload): pu.program = "process-upload" + pu.warnings = upload.warnings + return pu @try_or_reject @@ -258,6 +260,7 @@ def accept(directory, upload): cnf = Config() Logger.log(['ACCEPT', upload.changes.filename]) + print "ACCEPT" upload.install() @@ -297,6 +300,7 @@ def accept_to_new(directory, upload): cnf = Config() Logger.log(['ACCEPT-TO-NEW', upload.changes.filename]) + print "ACCEPT-TO-NEW" upload.install_to_new() # TODO: tag bugs pending @@ -316,6 +320,7 @@ def real_reject(directory, upload, reason=None, notify=True): cnf = Config() Logger.log(['REJECT', upload.changes.filename]) + print "REJECT" fs = upload.transaction.fs rejectdir = cnf['Dir::Reject']