Commit Graph

803 Commits

Author SHA1 Message Date
Dan McGee
8c1ae21e86 Remove print statement
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-27 13:12:11 -06:00
Dan McGee
fcc6d98bc4 reporead: fix small issues when loading files databases
We didn't verify that the version in the files database was the same as in
the SQL side of things, so we could load old files for a new package and
lose track of this fact. When loading files, ensure the database version
matches the version in the package before continuing with the file load
operation.

There are also a few other small updates in here, like skipping the sanity
check for filesonly as we never delete packages, and removing some
unnecessary string concatenation operations.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-04 22:11:00 -05:00
Dan McGee
01cb0348e3 reporead: Use transparent compression on open
And make filename check more lenient.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-04 21:43:39 -05:00
Dan McGee
3dea0da4a9 Ensure mirrorlist generator works if no status available
Saw this error come through on the live site today, as well as being
reproducible when no mirror check runs have happened in the last 24 hours on
a development machine. Let mirrors that have no available checks show up on
this page, but be sorted last and show a score of unknown.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-04 14:29:50 -05:00
Dan McGee
863d762817 reporead: orphaning code cleanup and debug removal
Cleanup to some of the orphan code cleanup, especially so we are never lying
in the percentage we print, and remove a bunch of debug prints that aren't
all that useful.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-04 14:27:45 -05:00
Dieter Plaetinck
543a096a26 Point to release specific wiki page for more info
Signed-off-by: Dieter Plaetinck <dieter@plaetinck.be>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-11-01 10:42:55 -05:00
Dan McGee
736c40e85e Convert a bunch of links to HTTPS
Now that the wiki is HTTPS for the most part, we should skip the redirects
and link directly. Also switch some www links for mailman resources to the
mailman subdomain.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-28 19:16:16 -05:00
Dan McGee
e57747442a Use HTTPS for links to AUR
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-28 19:04:56 -05:00
Dan McGee
da5d2fb008 Always use HTTPS for jQuery
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-28 19:04:33 -05:00
Dan McGee
50346c5f97 Use CDN on the artwork page
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-27 11:23:49 -05:00
Dan McGee
49ca9df209 Allow index and donate page to use resources from CDN
The index page is obviously hit more than just about every other page, so
this will benefit the most from moving the sponsor images to a different
domain. The donate page uses the same images.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-27 11:22:39 -05:00
Dan McGee
5266215047 Add tag for inserting CDN prefix on media URLs
This tag will just be placed before any media reference that is available on
the CDN; if the CDN is enabled and CDN_PATH/CDN_PATH_SECURE are defined the
correct URL will be generated.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-27 11:20:22 -05:00
Dan McGee
1a8114c00f Make package differences JS a bit more efficient
Use an id-based selector so we can get the necessary table rows to filter a
lot more quickly than a lengthy CSS selector. Also use traversal rather than
selectors when grabbing the package versions. This looked like a 3x-4x
increase in speed while testing locally.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-26 14:43:47 -05:00
Dan McGee
576118c45c Upgrade to jQuery 1.4.3
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-26 14:03:28 -05:00
Dan McGee
a5e8c5a8d5 Add flag date column to developer dashboard list
This only implements about 25% of FS#14656, but it is a good start and
trivial to add for now.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-21 18:14:02 -05:00
Dan McGee
1a4db3c7b9 Show a message when filelist is out of date
This addresses FS#21394 and ensures that the website is less misleading when
a package gets new files but they are not yet reflected in the shown list.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-21 10:55:44 -05:00
Dan McGee
4061ea44dd Apply testing style to multilib-testing
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-20 19:21:49 -05:00
Dan McGee
29218aa752 Package differences small updates
* Add 'multilib-testing' to the CSS class list to hide for [multilib]
* Select 'Only In Both' by default, which is probably the most useful option
* Unselect 'Minor Version Mismatches' by default

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-20 17:39:42 -05:00
Dan McGee
fe3858eee1 Show flag out-of-date date on package details page
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-19 09:12:06 -05:00
Dan McGee
b0131749ac Unify hyphenation of out-of-date text
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-19 09:05:26 -05:00
Dan McGee
778146cf61 Move hardcoded email address to settings file
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-18 15:00:44 -05:00
Dan McGee
c6f69b3582 Comment out paypal donations for now
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-18 12:11:33 -05:00
Dan McGee
8973ee37c2 Show all mirrors if no IP version specified
I'm eating my words on this one- we don't want to filter to none() if we
don't have an IP version specified, because people hitting the URL without a
ip_version parameter would no longer get any mirrors back. Filter if they
are provided by using a Q() object.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 19:15:50 -05:00
PyroPeter
952ca5f349 Allow filtering of mirrorlist by IP-version
Dan: Use a forms.MultipleChoiceField to match the protocol selection.

Signed-off-by: PyroPeter <abi1789@googlemail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:57:38 -05:00
Dan McGee
fe5e460d06 Mirror check script cleanup
Don't import all the constants from logging, just use logging.* instead.
Also, fix some typos that somehow snuck into one of my commits.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:44:17 -05:00
PyroPeter
28cc96af28 Add mirrorresolv manage.py command
Dan:
* Fix up some style issues such as spacing between operators
* Ensure one failed lookup doesn't crash the whole script
* Be silent out of the box if there are no errors, just like mirrorcheck

Signed-off-by: PyroPeter <abi1789@googlemail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:42:51 -05:00
PyroPeter
c057b079c7 Add has_ipv{4,6} to MirrorUrl
Dan: Add some more useful labels for use in the admin.

Signed-off-by: PyroPeter <abi1789@googlemail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:25:54 -05:00
PyroPeter
670aefbb14 Add 'All' choice and make it the default
Signed-off-by: PyroPeter <abi1789@googlemail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:14:10 -05:00
Dan McGee
97d1e4164b Connect post_save signals where they will always be triggered
We need to do this in the models.py files, otherwise the post_save signal
might not be connected right away on launch of the application. Move them
over there, add a dispatch_uid so it only gets hooked up once, and do some
other function moving around so we don't have circular imports.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:11:28 -05:00
Dan McGee
0c65360e6c Add ability to clear a cached function result
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-13 18:10:55 -05:00
Dan McGee
e2612ab3f6 mirrorcheck: catch and handle another socket timeout case
We were seeing processes hang on the Arch server. It looks like there are
ways for socket.timeout to come out of the main check code, so add another
except block to catch this case. In addition, make sure we always call
task_done() even on failures so processes eventually die.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-11 20:49:04 -05:00
Dan McGee
8e186efb2a Update link to AirVM
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-10 14:00:49 -05:00
Dan McGee
2b4be8b99c Fix trademarks email typo
FS#21157.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-10 08:42:38 -05:00
Dan McGee
16b27bc9e1 Fix potential race conditions in caching
Use a 'set to None' sentinel to indicate data updates are in progress and we
need to hold off a bit on caching a new value. This logic is gleamed from
the "Scaling Django" slides presented by Mike Malone and available freely on
SlideShare.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-08 17:09:34 -05:00
Dan McGee
1946d3d144 Fix README instructions
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-08 16:48:33 -05:00
Dan McGee
f8c2a15510 Ensure last modified times use UTC
We were cheating before and using non-UTC times; adjust the values we get
back from the database as appropriate so our times are not bogus.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 19:57:31 -05:00
Dan McGee
fc6e7113c4 Store package feed last modified date in memcached
Just like what we did for news items, we can do the same for packages.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 19:52:31 -05:00
Dan McGee
2016a9d6f7 Move import to top level
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 19:45:09 -05:00
Dan McGee
b2acd5cb94 Store latest news date in memcached
This saves two database queries each request, meaning no database hits at
all if we are just going to return a 304 response. It also requires adding a
post_save signal to ensure our cache is updated with the correct latest news
date upon saving a news item.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 19:43:13 -05:00
Dan McGee
cf7bf2de29 Factor out common last modified code for news feed
This will set up retrieving this value from memcached as well as some other
changes to come.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 19:16:40 -05:00
Dan McGee
82f3b02f60 Factor check completion pct into mirror score
Use it as the divisor in our slightly longer equation.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 08:09:07 -05:00
Dan McGee
2e299273e2 mirrorcheck: record duration on file not found errors
On an HTTP 404, FTP 550, or inability to parse the lastsync file, record the
duration of the check even though we couldn't get a time from the mirror.
This allows for these checks to show up as completed but in error, which is
more what.

Previously, inability to parse the date was also recorded as a success, so
change that to be a failure and record an error message with it.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-07 08:07:03 -05:00
Dan McGee
5fce0e249c Add a merchandise store
And also update the lingo we use here, 'schwag' implies free and can be a
bit confusing for people to see, especially non-English speakers.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-06 19:46:44 -05:00
Dan McGee
9e7e1a5ea6 Make it actually possible to upload a new dev image
We need to both submit the form with the correct encoding and then bind the
form itself to request.FILES and not just request.POST.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-06 01:05:29 -05:00
Angel Velasquez
d6d9a08e63 Adding changing of user profile details
The idea of this patch is allow to the developers who have an account, to
change their data without asking some admin to do it for them.

Dan: put private email address field back as it is used for a different
purpose; add some help text and field names as appropriate.

Signed-off-by: Angel Velasquez <angvp@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 15:11:50 -05:00
Dan McGee
d66d0e4300 Fix executable mode on image
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 12:24:01 -05:00
Dan McGee
35bcc1bc5f Make AirVM image an actual PNG
I saved this in here as a PNG when in fact it was a GIF. Use optipng to
convert it and get a smaller file size.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 12:17:06 -05:00
Dan McGee
2b8f7772ad Make it possible to override settings
By importing local settings at the end, you can override settings specified
in settings.py. Helpful for something like the Django debug toolbar. The
template loader needs to come last, however, in order to respect the
TEMPLATE_DEBUG setting.

Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 11:55:30 -05:00
Dan McGee
3972ba3bd2 Make manage.py use python2 binary
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 11:55:26 -05:00
Dan McGee
79a5f0334c Update AirVM branding
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05 11:54:17 -05:00