MarkAHershberger has submitted this change and it was merged.

Change subject: updater: Move rev_sha1 addition before convertUserOptions
......................................................................


updater: Move rev_sha1 addition before convertUserOptions

Execution of the script and addition of rev_sha1 are both 1.19
activities, but for some reason the issue has only shown up in 1.21.

* MysqlUpdater::getCoreUpdateList() declares that 'doMigrateUserOptions'
  should be executed before adding the field rev_sha1 into the revision table
* ConvertUserOptions::execute() calls User::saveSettings()
* User::saveSettings() at its very end calls 
$this->getUserPage()->invalidateCache()
  and that is where the revision query is joining the party.

Bug: 48820
Change-Id: Id0a6efc33a8c46fdc3e9c294aa2d005d46c7dda0
---
M includes/installer/MysqlUpdater.php
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  MarkAHershberger: Verified; Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/installer/MysqlUpdater.php 
b/includes/installer/MysqlUpdater.php
index 1c22afb..02faf7c 100644
--- a/includes/installer/MysqlUpdater.php
+++ b/includes/installer/MysqlUpdater.php
@@ -195,9 +195,9 @@
 
                        // 1.19
                        array( 'addIndex', 'logging',       'type_action',      
'patch-logging-type-action-index.sql'),
+                       array( 'addField', 'revision',      'rev_sha1',         
'patch-rev_sha1.sql' ),
                        array( 'doMigrateUserOptions' ),
                        array( 'dropField', 'user',         'user_options', 
'patch-drop-user_options.sql' ),
-                       array( 'addField', 'revision',      'rev_sha1',         
'patch-rev_sha1.sql' ),
                        array( 'addField', 'archive',       'ar_sha1',          
'patch-ar_sha1.sql' ),
                        array( 'addIndex', 'page', 
'page_redirect_namespace_len', 'patch-page_redirect_namespace_len.sql' ),
                        array( 'addField',      'uploadstash',  'us_chunk_inx', 
        'patch-uploadstash_chunk.sql' ),

-- 
To view, visit https://gerrit.wikimedia.org/r/76502
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id0a6efc33a8c46fdc3e9c294aa2d005d46c7dda0
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Matmarex <[email protected]>
Gerrit-Reviewer: MarkAHershberger <[email protected]>
Gerrit-Reviewer: Waldir <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to