summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-02-27Remove caching on reverse_conflictsDan McGee
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>
2013-02-26Use user.userprofile rather than user.get_profile()Dan McGee
The get_profile() function is deprecated as of Django 1.5. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-26Don't blow up in download template if no releases existDan McGee
Protect a few more things in {% if %} block logic. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-26Fix ALPM unittest to run when ALPM isn't presentDan McGee
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>
2013-02-26Merge branch 'django-1.5'Dan McGee
Conflicts: requirements.txt requirements_prod.txt
2013-02-26Bump Django requirement to 1.5Dan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-20Package sitemap adjustmentsDan McGee
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>
2013-02-20Fix some fallout with moving page to query paramsDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-19Update Django versionrelease_2013-02-19Dan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-16Make page a query string parameter on package searchDan McGee
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>
2013-02-16Remove configurable pagination for package searchDan McGee
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>
2013-02-16Paginator template cleanupDan McGee
2013-02-16Move all red/green/orange styles into single declarationDan McGee
We use these all over the place and can express them in a much shorter fashion. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-16Fix missing template variableDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-16Defer loading of some JS on public index pageDan McGee
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>
2013-02-10Fix split packages sitemaprelease_2013-02-16Dan McGee
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>
2013-02-09Use 'update_fields' model.save() kwargDan McGee
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>
2013-02-09Change caching strategy on package.applicable_archesDan McGee
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>
2013-02-09Revert "Reduce query count when retrieving satisfiers and providers"Dan McGee
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>
2013-02-09Remove {% load url from future %} from templatesDan McGee
This is now the default in Django 1.5. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-09reporead: remove batched_bulk_createDan McGee
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>
2013-02-09Update Konami JSDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-08Ensure todolists are consistently sortedDan McGee
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>
2013-02-08Upgrade D3 to 3.0.6release_2013-02-08Dan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-08Add a releases model sitemapDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-08Remove package seach by 'Last Updated After'Dan McGee
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>
2013-02-08Minify static files when running collectstaticDan McGee
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>
2013-02-04Add './' hack to generate_keyring as wellrelease_2013-02-04Dan McGee
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>
2013-02-04Update exception to DeveloperKey.DoesNotExistDan McGee
We aren't looking up users; we are looking up developer keys. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-03Use DeveloperKey model on package page and reportsDan McGee
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>
2013-02-03Update user_pgp_key_link template tag to use DeveloperKey modelDan McGee
The first of several small updates to use the new data we have available. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-02-03Add new pgp_import command; replaces import_signaturesDan McGee
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>
2013-02-03Add DeveloperKey modelDan McGee
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>
2013-02-03Move the home page script block further down the pageDan McGee
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>
2013-02-03Fix spacing issues in signoffs 'Show More' linksDan McGee
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>
2013-02-03Remove some whitespace from index templateDan McGee
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>
2013-02-03Run pngcrush and optipng over most static contentDan McGee
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>
2013-01-28Merge branch 'release'release_2013-01-28Dan McGee
2013-01-28Fix missing template variable for removed todolist packagesDan McGee
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>
2013-01-28Slight reorginization in the download page templateDan McGee
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>
2013-01-28Use torrent view and checksums where appropriateDan McGee
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>
2013-01-28Extract torrent trackers into a settings variableDan McGee
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>
2013-01-28Add MD5 and SHA1 fields for releasesDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-28Don't error on empty torrent dataDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-27Fix todolist maintainer sortingDan McGee
And also fix up a place where we dereferenced a variable in a template that doesn't exist. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-25Merge branch 'on-the-plane'release_2013-01-25Dan McGee
2013-01-23Use more modern verison of string template formattingDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-23Use querysets for calls to get_object_or_404(Package)Dan McGee
This works better in most cases since we need the architecture and repository objects at some point during the view process. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-22Slight optimization when searching for removed packageDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-22Spice up the release listing page a bitDan McGee
Add JS tablesorter code and add some style to the yesno column. Signed-off-by: Dan McGee <dan@archlinux.org>