Merge lp:~cjohnston/qa-dashboard/common-max-length into lp:qa-dashboard

Proposed by Chris Johnston
Status: Merged
Approved by: Chris Johnston
Approved revision: 645
Merged at revision: 653
Proposed branch: lp:~cjohnston/qa-dashboard/common-max-length
Merge into: lp:qa-dashboard
Diff against target: 155 lines (+129/-3)
2 files modified
common/migrations/0008_increase_max_length.py (+126/-0)
common/models.py (+3/-3)
To merge this branch: bzr merge lp:~cjohnston/qa-dashboard/common-max-length
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve
Joe Talbott Approve
Andy Doan (community) Approve
Review via email: mp+192154@code.launchpad.net

This proposal supersedes a proposal from 2013-10-21.

Commit message

Increase the max_length of sru model fields

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote : Posted in a previous version of this proposal

PASSED: Continuous integration, rev:645
http://10.97.0.26:8080/job/dashboard-ci/206/
Executed test runs:

Click here to trigger a rebuild:
http://10.97.0.26:8080/job/dashboard-ci/206/rebuild

review: Approve (continuous-integration)
Revision history for this message
Andy Doan (doanac) :
review: Approve
Revision history for this message
Joe Talbott (joetalbott) :
review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

PASSED: Continuous integration, rev:645
http://10.97.0.26:8080/job/dashboard-ci/216/
Executed test runs:

Click here to trigger a rebuild:
http://10.97.0.26:8080/job/dashboard-ci/216/rebuild

review: Approve (continuous-integration)
Revision history for this message
Chris Johnston (cjohnston) wrote :

The attempt to merge lp:~cjohnston/qa-dashboard/common-max-length into lp:qa-dashboard failed. Below is the output from the failed tests.

Creating test database for alias 'default'...
Type 'yes' if you would like to try deleting the test database 'test_qa_dashboard', or 'no' to cancel:
Got an error creating the test database: database "test_qa_dashboard" already exists

EOFError: EOF when reading a line

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'common/migrations/0008_increase_max_length.py'
2--- common/migrations/0008_increase_max_length.py 1970-01-01 00:00:00 +0000
3+++ common/migrations/0008_increase_max_length.py 2013-10-22 14:17:47 +0000
4@@ -0,0 +1,126 @@
5+# -*- coding: utf-8 -*-
6+import datetime
7+from south.db import db
8+from south.v2 import SchemaMigration
9+from django.db import models
10+
11+
12+class Migration(SchemaMigration):
13+
14+ def forwards(self, orm):
15+
16+ # Changing field 'Bug.bug_no'
17+ db.alter_column('bugs', 'bug_no', self.gf('django.db.models.fields.CharField')(max_length=4096))
18+
19+ # Changing field 'JenkinsBuild.build_number'
20+ db.alter_column('jenkins_builds', 'build_number', self.gf('django.db.models.fields.CharField')(max_length=4096))
21+
22+ # Changing field 'JenkinsBuild.build_description'
23+ db.alter_column('jenkins_builds', 'build_description', self.gf('django.db.models.fields.CharField')(max_length=4096))
24+
25+ def backwards(self, orm):
26+
27+ # Changing field 'Bug.bug_no'
28+ db.alter_column('bugs', 'bug_no', self.gf('django.db.models.fields.CharField')(max_length=255))
29+
30+ # Changing field 'JenkinsBuild.build_number'
31+ db.alter_column('jenkins_builds', 'build_number', self.gf('django.db.models.fields.CharField')(max_length=50))
32+
33+ # Changing field 'JenkinsBuild.build_description'
34+ db.alter_column('jenkins_builds', 'build_description', self.gf('django.db.models.fields.CharField')(max_length=1024))
35+
36+ models = {
37+ u'auth.group': {
38+ 'Meta': {'object_name': 'Group'},
39+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
40+ 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
41+ 'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
42+ },
43+ u'auth.permission': {
44+ 'Meta': {'ordering': "(u'content_type__app_label', u'content_type__model', u'codename')", 'unique_together': "((u'content_type', u'codename'),)", 'object_name': 'Permission'},
45+ 'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
46+ 'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['contenttypes.ContentType']"}),
47+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
48+ 'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
49+ },
50+ u'auth.user': {
51+ 'Meta': {'object_name': 'User'},
52+ 'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
53+ 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
54+ 'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
55+ 'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}),
56+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
57+ 'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
58+ 'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
59+ 'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
60+ 'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
61+ 'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
62+ 'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
63+ 'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': u"orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}),
64+ 'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'})
65+ },
66+ u'common.artifact': {
67+ 'Meta': {'object_name': 'Artifact', 'db_table': "'common_artifacts'"},
68+ 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
69+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
70+ 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
71+ 'jenkins_build': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['common.JenkinsBuild']"}),
72+ 'name': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
73+ 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
74+ 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
75+ 'url': ('django.db.models.fields.URLField', [], {'max_length': '200'})
76+ },
77+ u'common.bug': {
78+ 'Meta': {'object_name': 'Bug', 'db_table': "'bugs'"},
79+ 'assignee': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
80+ 'bug_no': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
81+ 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
82+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
83+ 'importance': ('django.db.models.fields.CharField', [], {'default': "u'unknown'", 'max_length': '4096'}),
84+ 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
85+ 'project': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
86+ 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
87+ 'status': ('django.db.models.fields.CharField', [], {'default': "u'unknown'", 'max_length': '4096'}),
88+ 'title': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
89+ 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
90+ },
91+ u'common.jenkinsbuild': {
92+ 'Meta': {'unique_together': "(('job', 'build_number'),)", 'object_name': 'JenkinsBuild', 'db_table': "'jenkins_builds'"},
93+ 'bugs': ('django.db.models.fields.related.ManyToManyField', [], {'related_name': "'build_bugs'", 'symmetrical': 'False', 'to': u"orm['common.Bug']"}),
94+ 'build_description': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '4096'}),
95+ 'build_number': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
96+ 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
97+ 'failed': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
98+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
99+ 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
100+ 'job': ('django.db.models.fields.related.ForeignKey', [], {'to': u"orm['common.JenkinsJob']"}),
101+ 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
102+ 'ran_at': ('django.db.models.fields.DateTimeField', [], {}),
103+ 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'})
104+ },
105+ u'common.jenkinsjob': {
106+ 'Meta': {'object_name': 'JenkinsJob', 'db_table': "'jenkins_jobs'"},
107+ 'created_at': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}),
108+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
109+ 'internal': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
110+ 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '200'}),
111+ 'publish': ('django.db.models.fields.BooleanField', [], {'default': 'True'}),
112+ 'updated_at': ('django.db.models.fields.DateTimeField', [], {'auto_now': 'True', 'blank': 'True'}),
113+ 'url': ('django.db.models.fields.URLField', [], {'max_length': '200'})
114+ },
115+ u'common.userprofile': {
116+ 'Meta': {'object_name': 'UserProfile', 'db_table': "'custom_user_profile'"},
117+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
118+ 'use_private_url': ('django.db.models.fields.BooleanField', [], {'default': 'False'}),
119+ 'user': ('django.db.models.fields.related.OneToOneField', [], {'to': u"orm['auth.User']", 'unique': 'True'})
120+ },
121+ u'contenttypes.contenttype': {
122+ 'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
123+ 'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
124+ u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
125+ 'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
126+ 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
127+ }
128+ }
129+
130+ complete_apps = ['common']
131\ No newline at end of file
132
133=== modified file 'common/models.py'
134--- common/models.py 2013-10-10 20:26:52 +0000
135+++ common/models.py 2013-10-22 14:17:47 +0000
136@@ -56,7 +56,7 @@
137
138 class Meta:
139 db_table = 'bugs'
140- bug_no = models.CharField(max_length=255)
141+ bug_no = models.CharField(max_length=4096)
142 title = models.CharField(max_length=4096, null=True)
143 status = models.CharField(
144 max_length=4096,
145@@ -131,8 +131,8 @@
146 failed = models.BooleanField(default=True)
147 bugs = models.ManyToManyField(Bug, related_name='build_bugs')
148 ran_at = models.DateTimeField('date run')
149- build_number = models.CharField(max_length=50)
150- build_description = models.CharField(max_length=1024, default='')
151+ build_number = models.CharField(max_length=4096)
152+ build_description = models.CharField(max_length=4096, default='')
153
154 def __unicode__(self):
155 return "{} - {}".format(

Subscribers

People subscribed via source and target branches