Age | Commit message (Collapse) | Author | Files | Lines |
|
This reverts commit 3c4ceb16. We don't need this anymore as bulk_create
gets automatic batching now on sqlite3 so it is safe to use.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We have been better about doing this to most of our models, but the ones
here didn't have a created field. Add it where appropriate and set a
reasonably old default value.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
For now, it is not included in the default selection, but we have a few
existing mirrors that do support it.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This moved around in Django 1.5, so add it to the override list so it
continues to be ignore like it was in older versions of Django.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Seems the Django caching layer has changed quite a bit and is doing all
sorts of funky s**t at this point. Yay for errors!
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We started seeing this in production with memcached usage and the
upgrade to Django 1.5:
PicklingError: Can't pickle <class 'devel.models.UserProfile_allowed_repos'>: attribute lookup devel.models.UserProfile_allowed_repos failed
Without having time to investigate further, something changed, likely
due to the whole user profile/configurable user model shenanigans done
in Django 1.5. For now, simply don't cache this attribute to work around
the problem.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
The get_profile() function is deprecated as of Django 1.5.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Protect a few more things in {% if %} block logic.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This gets some proper unittest skip decorator action now in addition to
adding more testing around everything.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Conflicts:
requirements.txt
requirements_prod.txt
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Adjust changefreq and priority based on the repository the package is
in. Testing and staging have quick turnover so set the changefreq to
'daily'. Additionally, give staging packages a super low priority of 0.1
and testing a slightly lowered priority of 0.4.
We didn't include staging packages before, but since search engines are
finding them anyway, we might as well. This gives us a chance to share
how important the page is as well, which they could only guess before.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This is a bit silly to encode in the URL, or at least makes it much
harder to screen out via robots.txt and other such things.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Switch it to a hardcoded value of 100 for all searches instead. It
didn't make much sense having a page number be part of the URL and a
limit value being part of the query string.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
|
|
We use these all over the place and can express them in a much shorter
fashion.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We don't need typeahead and easter eggs working right away, so defer
them into a onload event.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We had a ton of duplicate entries included due to the query implicitly
including a 'GROUP BY' clause on the default sorting by pkgname. Fix it
and cut the sitemap down to the correct size without duplicate entries.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This was added in Django 1.5 and allows saving only a subset of a
model's fields. It makes sense in a few cases to utilize it.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Rather than use the Django cache for this (aka memcached), just do it on
a per-object instantiation basis. This means no external services calls
except the first time to the database, which should be quite a bit
faster.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This reverts commit 20b64e42672d185821cc584dfa4b133ee259a144.
Django 1.5 fixed this issue and now parent objects are automatically
attached to their children when queries go through the related manager.
See "Caching of related model instances" in the release notes.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This is now the default in Django 1.5.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Now that Django 1.5 is out and realized SQLite3 only allows for 999
parameters per SQL call, we don't need to manually batch things up
anymore and can let the underlying bulk_create code do it for us.
This basically reverts commit 88ee61a39ac3.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This is for the public view page; we had no order_by() call so lists
could be displayed in seemingly random order.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
It is a lot easier to just sort the list rather than mess with this
particular field, which didn't even allow you to specify a range or
direction to search in.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This doesn't do any super optimizations, but does run the very basic
cssmin and jsmin Python tools over the static resources we serve up.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
If you specify a relative path to gpg without a slash character, it
interprets as relative to ~/.gnupg, which is stupid.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We aren't looking up users; we are looking up developer keys.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This introduces the new model to the package page so subkey signings
show up as attributed to the original developer. We also teach the
mismatched signatures report to recognize all keys and subkeys of a
given developer, cutting down on some of the bogus results.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
The first of several small updates to use the new data we have
available.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This command now imports keys, subkeys, and signatures of those keys &
subkeys. This will allow us to actually match developers with their
packages signed by subkeys rather than the primary key.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We're starting to see developers use subkeys of their primary key to
sign packages, which we aren't handling well in the web interface. These
subkeys show up as unknown, which isn't strictly true. Start the process
of being able to handle these keys by adding a model that will store all
known keys and subkeys and the relationships among them, as well as
which developer owns each.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Put it after every bit of HTML content, including the page footer. Right
now this was the only page using this block in the main template; we
should move some other pages using a lot of JS to this format as well.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
When we had a simple multi-line message here, we would end up with too
much spacing wherever the link had planted itself due to the div adding
visual whitespace. Remove the div completely when the link is clicked to
remedy this.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We had a lot going on here in the news section as far as Django template
tags go, so remove some whitespace to prevent so many empty lines from
being ommitted. This doesn't remove all of it from the generated HTML,
but does cut it down significantly.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
The programs have improved a bit and found some room for optimization,
especially in the static logo content. Some files were reduced in size
by 50% or more.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
|
|
When there was no longer an attached package, running in template debug
mode showed we were trying to dereference a variable that didn't exist.
Fix the issue by adding a bit more to the if conditional block.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Move things up that don't belong to the torrent section; make magnet
link more prominent by using a bulleted list.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
We no longer need to link externally to these items since we have all
the data available in the web application now.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This allows them to be overridden and changed in a central location,
like we do with the SVN URL, PXE boot URL, etc.
Signed-off-by: Dan McGee <dan@archlinux.org>
|