X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=inline;f=dak%2Fprocess_accepted.py;h=7b78f08c73f26b2327181b258738e18beba8ad4a;hb=7e1fd15629858d8b3437cb7626f853e74c461ec1;hp=b203f498191d41a819885cab17ae03337b6f0a63;hpb=731c2232d9964d0f441ff5ea386e5e9937aa77ab;p=dak.git diff --git a/dak/process_accepted.py b/dak/process_accepted.py index b203f498..7b78f08c 100755 --- a/dak/process_accepted.py +++ b/dak/process_accepted.py @@ -311,17 +311,24 @@ def add_deb_to_db(u, filename, session): for suite_name in u.pkg.changes["distribution"].keys(): ba = BinAssociation() ba.binary_id = bin.binary_id - ba.suite_id = get_suite(suite_name).suite_id + suite = get_suite(suite_name) + ba.suite_id = suite.suite_id + + component_id = bin.poolfile.location.component_id; + component_id = bin.poolfile.location.component_id; + + contents = copy_temporary_contents(bin os.path.basename(filename), None, session) + if not contents: + print "REJECT\nCould not determine contents of package %s" % bin.package + session.rollback() + raise MissingContents, "No contents stored for package %s, and couldn't determine contents of %s" % (bin.package, filename) + + session.add(ba) + session.flush() - # Deal with contents - disabled for now - #contents = copy_temporary_contents(bin.package, bin.version, bin.architecture.arch_string, os.path.basename(filename), None, session) - #if not contents: - # print "REJECT\nCould not determine contents of package %s" % bin.package - # session.rollback() - # raise MissingContents, "No contents stored for package %s, and couldn't determine contents of %s" % (bin.package, filename) def install(u, session, log_urgency=True):