Page MenuHomePhabricator

CX2: Template adaptation
Closed, ResolvedPublic

Description

A problem with CX1 template adaptation is, the solution was not easily integratable to the references when reference definition is template.

There is also a consideration of VE template modeling and reusing it to model the CX template classes. Ofcourse we will require a pair of such models for source and target language.

Pending:

  • cxserver: Use the param mapping to build target template definition.
  • cxserver: Update tests for MWTemplate.js
  • cxserver: If template data not found, try to extract info from source code of template like we do in CX1 - ST working on.
  • The templates should be renderered in source and target language wikis instead of Localwiki. Customize ve.ce.MWTransclusionNode so that the api pointing to correct wikis
  • fetch the template data from correct wiki instead of localhost
  • T192271: CX2: Communicate template could not be adapted

Event Timeline

santhosh created this task.Apr 4 2017, 6:14 AM
Arrbee reassigned this task from santhosh to Nikerabbit.Sep 20 2017, 7:13 AM

Change 375789 had a related patch set uploaded (by Nikerabbit; owner: Nikerabbit):
[mediawiki/services/cxserver@master] Adapt template names if present in Wikidata

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

Per T150652: Content Translation feature parity checklist post VisualEditor integration I am currently working on template name adaptation (using Wikidata via interwiki links) and simple parameter mapping (exact & case insensitive matching using templatedata). This doesn't complete this ticket though.

Arrbee added a subscriber: Arrbee.Sep 28 2017, 6:47 AM

Per T150652: Content Translation feature parity checklist post VisualEditor integration I am currently working on template name adaptation (using Wikidata via interwiki links) and simple parameter mapping (exact & case insensitive matching using templatedata). This doesn't complete this ticket though.

Additional note: This is expected to complete the immediate priority items as per T150652: Content Translation feature parity checklist post VisualEditor integration. Further follow-up on template adaptation will also be determined by a final confirmation on the UI design expected for translation view.

Change 381418 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/services/cxserver@master] Template adaptation: Implement template param name matching

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

This comment was removed by santhosh.
santhosh updated the task description. (Show Details)Oct 3 2017, 7:11 AM

Change 381943 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/services/cxserver@master] Templates: If templatedata not found, try to extract info from source code

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

santhosh updated the task description. (Show Details)Oct 3 2017, 8:56 AM
Arrbee updated the task description. (Show Details)Oct 4 2017, 7:21 AM

Change 381418 merged by jenkins-bot:
[mediawiki/services/cxserver@master] Template adaptation: Implement template param name matching

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

Change 381943 merged by Nikerabbit:
[mediawiki/services/cxserver@master] Templates: If templatedata not found, try to extract info from source code

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

Arrbee updated the task description. (Show Details)Oct 10 2017, 5:36 PM
Nikerabbit removed Nikerabbit as the assignee of this task.Nov 3 2017, 8:58 AM
Nikerabbit removed a project: Patch-For-Review.

Description of this ticket does not reflect what needs to be done in the future to resolve this. There are three bullet points, which are marked as checked.

Please update ticket description with required work for template adaption or create new ticket if this one doesn't suit the needs anymore. @Pginer-WMF, you may want to provide your inputs as well, just pinging you.

santhosh updated the task description. (Show Details)Apr 6 2018, 9:59 AM

Change 424549 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/extensions/ContentTranslation@master] CX2: Render templates in correct wiki

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

santhosh updated the task description. (Show Details)Apr 6 2018, 10:00 AM

After https://gerrit.wikimedia.org/r/424549, the adapted template having Tamil(target language) rendering

santhosh claimed this task.Apr 6 2018, 11:46 AM

Change 424983 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/extensions/ContentTranslation@master] ve.init.mw.CXTarget: Customize parsefragment

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

Change 424549 abandoned by Santhosh:
CX2: Render templates in correct wiki

Reason:
Abandoning in favor of https://gerrit.wikimedia.org/r/c/424983/

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

Change 424983 merged by jenkins-bot:
[mediawiki/extensions/ContentTranslation@master] ve.init.mw.CXTarget: Customize parsefragment

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

https://gerrit.wikimedia.org/r/424983 was deployed to wmf.1 - checked there (used the same example as @santhosh):

@santhosh is something else needs to be done regarding three remaining items on the ticket?

The templates should be renderered in source and target language wikis instead of Localwiki. Customize ve.ce.MWTransclusionNode so that the api pointing to correct wikis
Use the cx adaptation information to inform user about the status of template adaptation
fetch the template data from correct wiki instead of localhost

Yes, this ticket is not finished. We are yet to actually work on template support in frontend.

santhosh removed santhosh as the assignee of this task.May 2 2018, 3:55 AM
santhosh moved this task from CX2 to Needs Triage on the ContentTranslation board.
santhosh updated the task description. (Show Details)Aug 6 2018, 8:47 AM
Pginer-WMF closed this task as Resolved.Aug 6 2018, 8:49 AM
Pginer-WMF claimed this task.
Pginer-WMF updated the task description. (Show Details)

Most of the infrastructure work for template adaptation has been completed, and the remaining task has now a separate follow-up ticket: T192271: CX2: Communicate template could not be adapted