summaryrefslogtreecommitdiffstats
path: root/main/migrations
AgeCommit message (Collapse)AuthorFilesLines
2014-03-22Make filename and directory name fields accept longer valuesDan McGee1-0/+112
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-11-07Drop old base64-ed PGP signature columnDan McGee2-1/+113
We've moved onto bytes only now. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-11-07Move signature data from base64 string to bytes typeDan McGee1-0/+125
Signed-off-by: Dan McGee <dan@archlinux.org>
2013-11-07Add new `signature_bytes` field on package modelDan McGee1-0/+115
Now that we have a BinaryField option in Django 1.6, put it to use. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-04-22Add 'required_signoffs' field to Arch modelDan McGee1-0/+112
This will indicate how many signoffs are required for packages of the given architecture. Set the default to 2 as it currently stands. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-04-17Various minor code cleanups and fixesDan McGee1-1/+0
Most of these were suggested by PyCharm, and include everything from little syntax issues and other bad smells to dead or bad code. Signed-off-by: Dan McGee <dan@archlinux.org>
2013-01-16Clean up and make several migrations modernDan McGee5-32/+22
This moves most migrations to the v2 format that have been presenting some issues. One missing depends_on relationship has been added, and we allow an index to not be dropped if it does not exist due to the shittyness in sqlite3 actually keeping indexes across DDL on that table. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-12-31Add 'created' field to packages modelDan McGee1-0/+116
This will be used to eventually implement the UI side of FS#13441, but to do that, we first need the data. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-12-28Remove old todo list modelsDan McGee1-0/+133
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-12-28Fix "RuntimeWarning: DateTimeField received a naive datetime" warningsDan McGee1-2/+2
When running tests, we can find old migrations that didn't use datetime objects with timezones attached. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-10-18Clean up create index migrationDan McGee1-2/+2
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-10-18Modernize initial main migrationDan McGee1-3/+3
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-08-08Push more default values down into the databaseDan McGee5-5/+5
This makes it easier to do manual manipulation/insertion/etc. at the database level, as well as just making things act more sane from an overall software stack perspective. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-19Drop old PackageDepend modelDan McGee1-0/+135
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-26Convert old index addition migration to new formatDan McGee1-19/+3
This moves it to the new class-based extending SchemaMigration format, in hopes that it will play nicer when starting and migrating from scratch. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-22Add an index on packages last update columnDan McGee1-0/+131
Not sure why we don't have this already, given both the home page, the packages page when ordered by last update, and the generated feeds would see immediate benefit from it. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-20Fix ContentType related migrationsDan McGee3-29/+5
This should fix the issues reported in FS#23228 for the most part. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-20UserProfile model and fields shuffleDan McGee9-9/+146
Move this model into the devel/ application, and move the PGPKeyField which is used only by these models into the application as well. This involves updating some old migrations along the way to ensure we don't reference a field class that no longer exists. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-08Add migrations for on_delete attributesDan McGee1-0/+160
I don't think these end up doing anything at the database level, but since South insists on generating alter_column() calls for these changes, do them once so they don't keep reappearing in auto-generated future migrations. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-03-24Make all datetime objects fully timezone awareDan McGee2-2/+8
This is most of the transition to Django 1.4 `USE_TZ = True`. We need to ensure we don't mix aware and non-aware datetime objects when dealing with datetimes in the code. Add a utc_now() helper method that we can use most places, and ensure there is always a timezone attached when necessary. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-03-08Tabs to spaces conversionDan McGee1-2/+2
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-11-21Better support for non-latin full namesDan McGee1-0/+153
Add a 'latin_name' field to the user profile so we can better support those developers with names in non-Latin scripts, and yet still show a Latin name as necessary on the developer profile page. This field only shows up if populated. Also, use consistent sorting everywhere- rather than using username, always use first_name and last_name fields. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-11-17Change package description to a text fieldDan McGee1-0/+153
No need to have length restrictions on this. Although long descriptions are frowned upon, we shouldn't truncate them if someone really wants one. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-11-17Ensure reporead is protected against simultaneous runsDan McGee1-0/+155
This adds a bunch of transaction magic and SELECT FOR UPDATE stuff to reporead to cope with the now-concurrent runs of reporead we get when invoked from our inotify-based updater. The collision occurs with 'any' architecture packages as both repo databases contain the new version, and the updates occur at exactly the same time. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-11-01Add created column to Donor modelDan McGee1-0/+157
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-08-17Add PGP signature package fieldDan McGee1-0/+152
And add eventual display code for it to the details template, but don't show it yet as no packages will have it. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-06Delete old signoff modelDan McGee1-0/+166
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-07-05Allow more lenient data entry for PGP key fieldDan McGee1-0/+160
Don't allow the max_length parameter to make it through to the HTML form, silently cutting off HTML cut and pastes. Trim out spaces automatically, as well as '0x' and '2048R/' type prefixes. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-15Mark several package columns as non-NULLDan McGee1-0/+163
These have been around for a long time now so they don't need to be NULL-able anymore. We can also add a custom field type for our numbers to at least get a check constraint at the Django level. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-02Add a PGP key field on the dev profileDan McGee1-0/+160
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-19Add a "Report a Bug" linkDan McGee1-0/+158
We need Flyspray category data to make this more useful, and we can prefill the Subject and Category fields (along with putting it on the right project). Implements FS#23751. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-04-08Add some migrations to convert database to UTC timeDan McGee1-0/+180
This follows the earlier commit where we make sure any value going to or being pulled from the database is UTC. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-03-23Add 'staging' field to Repo modelDan McGee1-0/+157
First steps towards implementing FS#23298. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-03-23Add index to todo list date addedDan McGee1-0/+156
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-03-15Make todo list DateField a DateTimeFieldDan McGee1-0/+156
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-03-13Add package epoch supportDan McGee1-0/+162
This comes with pacman 3.5, replacing the old "force" PKGBUILD option. We parse it and store it for now, but don't display it anywhere just yet. Also update a few queries relying on version differences in any of the multiple parts. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-02-22Use new split package file fields everywhereDan McGee1-0/+158
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-02-22Add migration to split package files into partsDan McGee1-0/+186
This datamigration is a bit more tricky and we do some DB-specific stuff so it can be done a lot faster- we are dealing with millions of rows in this migration in production. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-02-22Add new file and directory parts to package filesDan McGee1-0/+166
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-02-15Move license to a related modelDan McGee1-0/+157
This allows us to store multiple licenses per package in a more elegant fashion, and will later allow us to search and filter on this information. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-02-15Allow optional deps in depends modelDan McGee1-0/+156
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-01-08Add time zone field to developer profileDan McGee1-0/+154
This will be used by the developer world clock page soon to come. Default everyone to "UTC" for now. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-05Make user profile a OneToOneFieldDan McGee1-0/+151
We had this set up as a unique ForeignKey before, which adds some indirection due to the RelatedManager object being there. By making it a OneToOneField, we can get the profile object directly, enforce uniqueness, and also use it in select_related() calls to make our profiles page a bit more efficient. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-10-01Allow donors to be invisibleDan McGee1-0/+151
Signed-off-by: Dan McGee <dan@archlinux.org>
2010-09-09After moving models, update content type tableDan McGee1-0/+169
The one thing that people forget to mention when moving models from one Django app to another. I was fooled here. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-09-08Add metadata to Arch tableDan McGee2-0/+302
Add a column flagging whether this architecture is agnostic (e.g. 'any') or not. This will remove the hardcoded name checks we have all over the place and replace it with a boolean. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-09-08Move news model to an appropriate placeDan McGee1-0/+153
Never would have guessed it should actually be in news/models.py. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-09-06Move mirror models out of main appDan McGee1-0/+161
South actually makes this relatively painless if you get everything right, so might as well start getting these out of the legacy main application to eventually eliminate models being separate from their views. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-08-25Simple migration to populate repo dataDan McGee1-0/+194
Also update the repos fixture to include the new fields and [multilib] repository. Signed-off-by: Dan McGee <dan@archlinux.org>
2010-08-25Add more metadata to repo modelDan McGee1-0/+200
Things like the flyspray project ID and SVN repo path should go here rather than being hardcoded in the code. Signed-off-by: Dan McGee <dan@archlinux.org>