From f4e2d143adca93b6ebba051e5f1c3e97266bb747 Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Mon, 24 Apr 2017 21:16:04 +0200 Subject: Explicitly initialize PackageBases.FlaggerComment Since commit 09cb61a (schema: Remove invalid default values for TEXT columns, 2017-04-15), the PackageBases.FlaggerComment field no longer has a default value. Initialize this field explicitly whenever a new row is added to the PackageBases table. Signed-off-by: Lukas Fleischer --- aurweb/git/update.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'aurweb/git/update.py') diff --git a/aurweb/git/update.py b/aurweb/git/update.py index 09a57ef0..c9a98d07 100755 --- a/aurweb/git/update.py +++ b/aurweb/git/update.py @@ -61,8 +61,9 @@ def create_pkgbase(conn, pkgbase, user): now = int(time.time()) cur = conn.execute("INSERT INTO PackageBases (Name, SubmittedTS, " + - "ModifiedTS, SubmitterUID, MaintainerUID) VALUES " + - "(?, ?, ?, ?, ?)", [pkgbase, now, now, userid, userid]) + "ModifiedTS, SubmitterUID, MaintainerUID, " + + "FlaggerComment) VALUES (?, ?, ?, ?, ?, '')", + [pkgbase, now, now, userid, userid]) pkgbase_id = cur.lastrowid cur = conn.execute("INSERT INTO PackageNotifications " + -- cgit v1.2.3-24-g4f1b