Description:
resize submissions.source field from "TEXT" to "MEDIUMTEXT"
Commit status:
[Not Reviewed]
References:
Comments:
0 Commit comments 0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
Add another comment

r712:04cb04cf3cfa - - 2 files changed: 15 inserted, 15 deleted

@@ -8,7 +8,7
8 before_validation :assign_language
8 before_validation :assign_language
9
9
10 validates_presence_of :source
10 validates_presence_of :source
11 - validates_length_of :source, :maximum => 100_000, :allow_blank => true, :message => 'too long'
11 + validates_length_of :source, :maximum => 100_000, :allow_blank => true, :message => 'code too long, the limit is 100,000 bytes'
12 validates_length_of :source, :minimum => 1, :allow_blank => true, :message => 'too short'
12 validates_length_of :source, :minimum => 1, :allow_blank => true, :message => 'too short'
13 validate :must_have_valid_problem
13 validate :must_have_valid_problem
14 validate :must_specify_language
14 validate :must_specify_language
@@ -11,11 +11,11
11 #
11 #
12 # It's strongly recommended that you check this file into your version control system.
12 # It's strongly recommended that you check this file into your version control system.
13
13
14 - ActiveRecord::Schema.define(version: 20170914150742) do
14 + ActiveRecord::Schema.define(version: 20180612102327) do
15
15
16 create_table "announcements", force: :cascade do |t|
16 create_table "announcements", force: :cascade do |t|
17 t.string "author", limit: 255
17 t.string "author", limit: 255
18 - t.text "body", limit: 16777215
18 + t.text "body", limit: 65535
19 t.boolean "published"
19 t.boolean "published"
20 t.datetime "created_at", null: false
20 t.datetime "created_at", null: false
21 t.datetime "updated_at", null: false
21 t.datetime "updated_at", null: false
@@ -50,7 +50,7
50 end
50 end
51
51
52 create_table "descriptions", force: :cascade do |t|
52 create_table "descriptions", force: :cascade do |t|
53 - t.text "body", limit: 16777215
53 + t.text "body", limit: 65535
54 t.boolean "markdowned"
54 t.boolean "markdowned"
55 t.datetime "created_at", null: false
55 t.datetime "created_at", null: false
56 t.datetime "updated_at", null: false
56 t.datetime "updated_at", null: false
@@ -62,7 +62,7
62 t.string "value", limit: 255
62 t.string "value", limit: 255
63 t.datetime "created_at", null: false
63 t.datetime "created_at", null: false
64 t.datetime "updated_at", null: false
64 t.datetime "updated_at", null: false
65 - t.text "description", limit: 16777215
65 + t.text "description", limit: 65535
66 end
66 end
67
67
68 create_table "grader_processes", force: :cascade do |t|
68 create_table "grader_processes", force: :cascade do |t|
@@ -126,7 +126,7
126 t.integer "sender_id", limit: 4
126 t.integer "sender_id", limit: 4
127 t.integer "receiver_id", limit: 4
127 t.integer "receiver_id", limit: 4
128 t.integer "replying_message_id", limit: 4
128 t.integer "replying_message_id", limit: 4
129 - t.text "body", limit: 16777215
129 + t.text "body", limit: 65535
130 t.boolean "replied"
130 t.boolean "replied"
131 t.datetime "created_at", null: false
131 t.datetime "created_at", null: false
132 t.datetime "updated_at", null: false
132 t.datetime "updated_at", null: false
@@ -181,7 +181,7
181
181
182 create_table "sessions", force: :cascade do |t|
182 create_table "sessions", force: :cascade do |t|
183 t.string "session_id", limit: 255
183 t.string "session_id", limit: 255
184 - t.text "data", limit: 16777215
184 + t.text "data", limit: 65535
185 t.datetime "updated_at"
185 t.datetime "updated_at"
186 end
186 end
187
187
@@ -213,10 +213,10
213 t.binary "binary", limit: 65535
213 t.binary "binary", limit: 65535
214 t.datetime "submitted_at"
214 t.datetime "submitted_at"
215 t.datetime "compiled_at"
215 t.datetime "compiled_at"
216 - t.text "compiler_message", limit: 16777215
216 + t.text "compiler_message", limit: 65535
217 t.datetime "graded_at"
217 t.datetime "graded_at"
218 t.integer "points", limit: 4
218 t.integer "points", limit: 4
219 - t.text "grader_comment", limit: 16777215
219 + t.text "grader_comment", limit: 65535
220 t.integer "number", limit: 4
220 t.integer "number", limit: 4
221 t.string "source_filename", limit: 255
221 t.string "source_filename", limit: 255
222 t.float "max_runtime", limit: 24
222 t.float "max_runtime", limit: 24
@@ -247,8 +247,8
247
247
248 create_table "test_pairs", force: :cascade do |t|
248 create_table "test_pairs", force: :cascade do |t|
249 t.integer "problem_id", limit: 4
249 t.integer "problem_id", limit: 4
250 - t.text "input", limit: 4294967295
250 + t.text "input", limit: 16777215
251 - t.text "solution", limit: 4294967295
251 + t.text "solution", limit: 16777215
252 t.datetime "created_at", null: false
252 t.datetime "created_at", null: false
253 t.datetime "updated_at", null: false
253 t.datetime "updated_at", null: false
254 end
254 end
@@ -264,7 +264,7
264 t.datetime "updated_at", null: false
264 t.datetime "updated_at", null: false
265 t.datetime "submitted_at"
265 t.datetime "submitted_at"
266 t.datetime "compiled_at"
266 t.datetime "compiled_at"
267 - t.text "compiler_message", limit: 16777215
267 + t.text "compiler_message", limit: 65535
268 t.datetime "graded_at"
268 t.datetime "graded_at"
269 t.string "grader_comment", limit: 255
269 t.string "grader_comment", limit: 255
270 t.datetime "created_at", null: false
270 t.datetime "created_at", null: false
@@ -282,8 +282,8
282 t.integer "score", limit: 4
282 t.integer "score", limit: 4
283 t.text "input", limit: 4294967295
283 t.text "input", limit: 4294967295
284 t.text "sol", limit: 4294967295
284 t.text "sol", limit: 4294967295
285 - t.datetime "created_at", null: false
285 + t.datetime "created_at"
286 - t.datetime "updated_at", null: false
286 + t.datetime "updated_at"
287 end
287 end
288
288
289 add_index "testcases", ["problem_id"], name: "index_testcases_on_problem_id", using: :btree
289 add_index "testcases", ["problem_id"], name: "index_testcases_on_problem_id", using: :btree
@@ -308,10 +308,10
308 t.boolean "activated", default: false
308 t.boolean "activated", default: false
309 t.datetime "created_at"
309 t.datetime "created_at"
310 t.datetime "updated_at"
310 t.datetime "updated_at"
311 - t.string "section", limit: 255
312 t.boolean "enabled", default: true
311 t.boolean "enabled", default: true
313 t.string "remark", limit: 255
312 t.string "remark", limit: 255
314 t.string "last_ip", limit: 255
313 t.string "last_ip", limit: 255
314 + t.string "section", limit: 255
315 end
315 end
316
316
317 add_index "users", ["login"], name: "index_users_on_login", unique: true, using: :btree
317 add_index "users", ["login"], name: "index_users_on_login", unique: true, using: :btree
You need to be logged in to leave comments. Login now