diff options
author | Helmut Grohne <helmut@subdivi.de> | 2013-03-07 08:24:44 +0100 |
---|---|---|
committer | Helmut Grohne <helmut@subdivi.de> | 2013-03-07 08:24:44 +0100 |
commit | b3d4bbae6fa2810daf3481d8ba99675ffe3bce9e (patch) | |
tree | b3315876e6eb444e42518cf437c891720c4818d8 /importpkg.py | |
parent | 5b5cf7f2629c3a6c78f6057ff1e8476ff001409f (diff) | |
download | debian-dedup-b3d4bbae6fa2810daf3481d8ba99675ffe3bce9e.tar.gz |
integrate the source table into the package table
Diffstat (limited to 'importpkg.py')
-rwxr-xr-x | importpkg.py | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/importpkg.py b/importpkg.py index d63b85e..ef368c2 100755 --- a/importpkg.py +++ b/importpkg.py @@ -148,8 +148,8 @@ def process_package(db, filelike): (package,)) cur.execute("DELETE FROM content WHERE package = ?;", (package,)) - cur.execute("INSERT INTO package (package, version, architecture) VALUES (?, ?, ?);", - (package, version, architecture)) + cur.execute("INSERT INTO package (package, version, architecture, source) VALUES (?, ?, ?, ?);", + (package, version, architecture, source)) depends = control.relations.get("depends", []) depends = set(dep[0]["name"].encode("ascii") for dep in depends if len(dep) == 1) @@ -157,10 +157,6 @@ def process_package(db, filelike): (package,)) cur.executemany("INSERT INTO dependency (package, required) VALUES (?, ?);", ((package, dep) for dep in depends)) - cur.execute("DELETE FROM source WHERE package = ?;", - (package,)) - cur.execute("INSERT INTO source (source, package) VALUES (?, ?);", - (source, package)) break continue elif name == "data.tar.gz": |