summaryrefslogtreecommitdiff
path: root/devel/management
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2010-05-24 11:29:35 -0500
committerDan McGee <dan@archlinux.org>2010-05-24 11:29:35 -0500
commitb3e8354cdff4af8117feda0806a7c1104d5bb30e (patch)
treeeb1ef2c9dce6a3b428ab756d5ae7fd1377b6b550 /devel/management
parent5adceb6586afcac163b1abf9fb6f2d0f1b151b9a (diff)
reporead: use the DB package we already haverelease_2010-05-24
Rather than go to the database for every single package on something like a files update, use the one we already have. Duh. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'devel/management')
-rw-r--r--devel/management/commands/reporead.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/devel/management/commands/reporead.py b/devel/management/commands/reporead.py
index ee606846..6e71c26e 100644
--- a/devel/management/commands/reporead.py
+++ b/devel/management/commands/reporead.py
@@ -266,14 +266,12 @@ def db_update(archname, reponame, pkgs, options):
continue
else:
timestamp = datetime.now()
- pkg = Package.objects.get(
- pkgname=p.name,arch=architecture, repo=repository)
if filesonly:
- logger.info("Possibly populating files for package %s in database", p.name)
- populate_files(pkg, p)
+ logger.debug("Checking files for package %s in database", p.name)
+ populate_files(dbp, p)
else:
logger.info("Updating package %s in database", p.name)
- populate_pkg(pkg, p, force=force, timestamp=timestamp)
+ populate_pkg(dbp, p, force=force, timestamp=timestamp)
logger.info('Finished updating Arch: %s' % archname)