summaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2012-02-28 21:05:13 -0500
committerLuke Shumaker <LukeShu@sbcglobal.net>2012-02-28 21:05:13 -0500
commit9e90f1968802d350157bcbeef0cebd7d96eb1ada (patch)
tree1153f677b807c9d7f40ef2ce4f9ab692ac6979a0 /devel
parent60f9b3fe60d5e5b6049ef71d1dfb25dade4fd6a3 (diff)
parent20e9a83e05e352ec6e6f8fbe70457951cf9cd047 (diff)
Merge commit '20e9a83' from Archweb
Conflicts: main/fixtures/groups.json packages/templatetags/package_extras.py
Diffstat (limited to 'devel')
-rw-r--r--devel/management/commands/reporead.py11
-rw-r--r--devel/views.py2
2 files changed, 6 insertions, 7 deletions
diff --git a/devel/management/commands/reporead.py b/devel/management/commands/reporead.py
index bb7d1005..e226d3a0 100644
--- a/devel/management/commands/reporead.py
+++ b/devel/management/commands/reporead.py
@@ -374,10 +374,9 @@ def db_update(archname, reponame, pkgs, force=False):
timestamp = None
# for a force, we don't want to update the timestamp.
# for a non-force, we don't want to do anything at all.
- if pkg_same_version(pkg, dbpkg):
- if not force:
- continue
- else:
+ if not force and pkg_same_version(pkg, dbpkg):
+ continue
+ elif not force:
timestamp = datetime.utcnow()
# The odd select_for_update song and dance here are to ensure
@@ -386,7 +385,7 @@ def db_update(archname, reponame, pkgs, force=False):
with transaction.commit_on_success():
# TODO Django 1.4 select_for_update() will work once released
dbpkg = select_pkg_for_update(dbpkg)
- if pkg_same_version(pkg, dbpkg):
+ if not force and pkg_same_version(pkg, dbpkg):
logger.debug("Package %s was already updated", pkg.name)
continue
logger.info("Updating package %s", pkg.name)
@@ -413,7 +412,7 @@ def filesonly_update(archname, reponame, pkgs, force=False):
with transaction.commit_on_success():
if not dbpkg.files_last_update or not dbpkg.last_update:
pass
- elif dbpkg.files_last_update > dbpkg.last_update:
+ elif not force and dbpkg.files_last_update > dbpkg.last_update:
logger.debug("Files for %s are up to date", pkg.name)
continue
# TODO Django 1.4 select_for_update() will work once released
diff --git a/devel/views.py b/devel/views.py
index b9bd7cce..c888871d 100644
--- a/devel/views.py
+++ b/devel/views.py
@@ -123,7 +123,7 @@ class UserProfileForm(forms.ModelForm):
class Meta:
model = UserProfile
- exclude = ['allowed_repos', 'user']
+ exclude = ('allowed_repos', 'user', 'latin_name')
@login_required
@never_cache