From: Joerg Jaspert Date: Sat, 9 May 2009 16:52:58 +0000 (+0200) Subject: process-new X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=ac248cc46170af4620aafd918cf3f7d593c4a9da;p=dak.git process-new no longer check the daily lock when we start looking at a package, but when we try to do modifying actions. No reason to not allow people to do Check/Reject/Note, those are actions we can do whenever. Its just modifying overrides which *have* to be avoided at certain times. Signed-off-by: Joerg Jaspert --- diff --git a/dak/new_security_install.py b/dak/new_security_install.py index d674befd..f6a7354b 100755 --- a/dak/new_security_install.py +++ b/dak/new_security_install.py @@ -303,7 +303,10 @@ def remove_from_buildd(suites, filename): try: os.unlink(os.path.join(builddbase, s, filebase)) except OSError, e: - utils.warn("Problem removing %s from buildd queue %s [%s]" % (filebase, s, str(e))) + pass + # About no value printing this warning - it only confuses the security team, + # yet makes no difference otherwise. + #utils.warn("Problem removing %s from buildd queue %s [%s]" % (filebase, s, str(e))) def generate_advisory(template): diff --git a/dak/process_new.py b/dak/process_new.py index f8a6f40e..65b550bb 100755 --- a/dak/process_new.py +++ b/dak/process_new.py @@ -811,9 +811,14 @@ def do_byhand(): answer = answer[:1].upper() if answer == 'A': - done = 1 - for f in byhand: - del files[f] + try: + check_daily_lock() + done = 1 + for f in byhand: + del files[f] + except CantGetLockError: + print "Hello? Operator! Give me the number for 911!" + print "Dinstall in the locked area, cant process packages, come back later" elif answer == 'M': Upload.do_reject(1, Options["Manual-Reject"]) os.unlink(Upload.pkg.changes_file[:-8]+".dak") @@ -981,13 +986,6 @@ def do_pkg(changes_file): Upload.update_subst() files = Upload.pkg.files - try: - check_daily_lock() - except CantGetLockError: - print "Hello? Operator! Give me the number for 911!" - print "Dinstall in the locked area, cant process packages, come back later" - sys.exit(1) - try: with lock_package(Upload.pkg.changes["source"]): if not recheck(): @@ -1002,7 +1000,12 @@ def do_pkg(changes_file): (new, byhand) = check_status(files) if not new and not byhand: - do_accept() + try: + check_daily_lock() + do_accept() + except CantGetLockError: + print "Hello? Operator! Give me the number for 911!" + print "Dinstall in the locked area, cant process packages, come back later" except AlreadyLockedError, e: print "Seems to be locked by %s already, skipping..." % (e)