Page MenuHomePhabricator

Extension Duplicator needs to be updated due to MCR schema changes
Closed, DeclinedPublic

Description

Reported at https://www.mediawiki.org/wiki/Topic:Uvk534c3g65obfzp.

From @daniel :

Looking at https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/extensions/Duplicator/+/master/Duplicator.page.php it seems like Duplicator is incompatible with the MCR database schema (and will break for Actor migration and Comment migration as well).

To be MCR compatible, it will (depending on the $wgMultiContentRevisionSchemaMigrationStage) also copy the relevant rows in the slots table (entries in the content table can be shared between page copies), and possibly ignore the rev_text_id field. Similarly, depending on the value of $wgCommentTableSchemaMigrationStage and $wgActorTableSchemaMigrationStage, it needs to handle rev_user_text and rev_comment differently.

To remove the need for the extension to bind to the concrete database schema (not to migration stage config), it should probably create a new MutableRevisionRecord for each RevisionStoreRecord of the existing page, and use a PageUpdater to save them to the new page. This would completely hide any DB schema details, but it would also be slower. Some tweaks in core may be needed to enable sharing of content between pages, core currently only supports this between revisions on the same page at the moment.

Related Objects

StatusSubtypeAssignedTask
Declineddchen
OpenNone
OpenNone
DuplicateNone
OpenFeatureNone
OpenBUG REPORTNone
OpenNone
StalledNone
OpenFeatureNone
DuplicateNone
ResolvedNone
OpenNone
OpenNone
OpenFeatureNone
OpenNone
ResolvedNone
ResolvedNone
OpenFeatureNone
OpenNone
OpenFeatureNone
StalledNone
OpenNone
OpenNone
DeclinedNone

Event Timeline

Change 644546 had a related patch set uploaded (by Zoranzoki21; owner: Zoranzoki21):
[mediawiki/extensions/Duplicator@master] Make extension compatible with the current content of revision table

https://gerrit.wikimedia.org/r/644546

Change 644546 abandoned by Zoranzoki21:
[mediawiki/extensions/Duplicator@master] Make extension compatible with the MediaWiki 1.35 and newer

Reason:
Let's work on one by one option.

https://gerrit.wikimedia.org/r/644546

Kizule removed Kizule as the assignee of this task.Mar 5 2023, 4:29 AM
Kizule removed projects: User-Kizule, Patch-For-Review.
Kizule added a subscriber: Kizule.
Kizule removed a subscriber: Kizule.