summaryrefslogtreecommitdiff
path: root/src/mailman/database
diff options
context:
space:
mode:
Diffstat (limited to 'src/mailman/database')
-rw-r--r--src/mailman/database/schema/mm_20121015000000.py4
-rw-r--r--src/mailman/database/schema/sqlite_20121015000000_01.sql3
-rw-r--r--src/mailman/database/tests/test_migrations.py6
3 files changed, 8 insertions, 5 deletions
diff --git a/src/mailman/database/schema/mm_20121015000000.py b/src/mailman/database/schema/mm_20121015000000.py
index 7745b8d9b..dc688d33b 100644
--- a/src/mailman/database/schema/mm_20121015000000.py
+++ b/src/mailman/database/schema/mm_20121015000000.py
@@ -96,8 +96,10 @@ def upgrade_postgres(database, store, version, module_path):
store.execute('ALTER TABLE mailinglist DROP COLUMN send_reminders;')
store.execute('ALTER TABLE mailinglist DROP COLUMN subscribe_policy;')
store.execute('ALTER TABLE mailinglist DROP COLUMN unsubscribe_policy;')
- store.execute('ALTER TABLE mailinglist DROP COLUMN private_roster;')
store.execute(
'ALTER TABLE mailinglist DROP COLUMN subscribe_auto_approval;')
+ store.execute('ALTER TABLE mailinglist DROP COLUMN private_roster;')
+ store.execute(
+ 'ALTER TABLE mailinglist DROP COLUMN admin_member_chunksize;')
# Record the migration in the version table.
database.load_schema(store, version, None, module_path)
diff --git a/src/mailman/database/schema/sqlite_20121015000000_01.sql b/src/mailman/database/schema/sqlite_20121015000000_01.sql
index 0526f9c8e..3e2410c3b 100644
--- a/src/mailman/database/schema/sqlite_20121015000000_01.sql
+++ b/src/mailman/database/schema/sqlite_20121015000000_01.sql
@@ -28,6 +28,7 @@ ALTER TABLE ban_backup ADD COLUMN list_id TEXT;
-- REM unsubscribe_policy
-- REM subscribe_auto_approval
-- REM private_roster
+-- REM admin_member_chunksize
CREATE TABLE ml_backup (
id INTEGER NOT NULL,
@@ -36,7 +37,6 @@ CREATE TABLE ml_backup (
allow_list_posts BOOLEAN,
include_rfc2369_headers BOOLEAN,
created_at TIMESTAMP,
- admin_member_chunksize INTEGER,
next_request_id INTEGER,
next_digest_number INTEGER,
digest_last_sent_at TIMESTAMP,
@@ -137,7 +137,6 @@ INSERT INTO ml_backup SELECT
allow_list_posts,
include_rfc2369_headers,
created_at,
- admin_member_chunksize,
next_request_id,
next_digest_number,
digest_last_sent_at,
diff --git a/src/mailman/database/tests/test_migrations.py b/src/mailman/database/tests/test_migrations.py
index 16a536894..4b784d8b3 100644
--- a/src/mailman/database/tests/test_migrations.py
+++ b/src/mailman/database/tests/test_migrations.py
@@ -380,7 +380,8 @@ class TestMigration20121015Schema(MigrationTestBase):
(),
('new_member_options', 'send_reminders',
'subscribe_policy', 'unsubscribe_policy',
- 'subscribe_auto_approval', 'private_roster'),
+ 'subscribe_auto_approval', 'private_roster',
+ 'admin_member_chunksize'),
)
def test_post_upgrade_column_migrations(self):
@@ -394,7 +395,8 @@ class TestMigration20121015Schema(MigrationTestBase):
'20121015000000'],
('new_member_options', 'send_reminders',
'subscribe_policy', 'unsubscribe_policy',
- 'subscribe_auto_approval', 'private_roster'),
+ 'subscribe_auto_approval', 'private_roster',
+ 'admin_member_chunksize'),
())