Page MenuHomePhabricator

"Manage TemplateData" does not handle transcluded templatedata correctly
Open, NormalPublic

Description

When a template uses transcluded page containing <templatedata> tag, "Manage TemplateData" tool behaves incorrectly.

  1. Opening the tool when editing the template page itself, it behaves as if no templatedata tag exists
  2. Opening the tool when editing the transcluded page, does not suggest adding missing parameters.
  3. The tool suggest parameters to add, by looking at the tempalte page, but it does not mark parameters which *do not* exist in the template.

Requests:

  1. if a tempaltedata tag exists in a page transcluded in the tmpalte page, the tool should provide clear and visible warning "you are trying to create templatedata structure, but such a structure already exists in transcluded page <link to the page>
  2. allow the user to instruct the too to read the tempalte itself from another page: this will allow it to give relevant suggestions ("Add N suggested parameters") when editing the transcluded page contianing the tag
  3. parameters in TD which do not appear to exist in the tempalte, should be marked in the tool.

peace.

Event Timeline

Kipod created this task.Mar 26 2016, 6:04 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 26 2016, 6:04 PM
AlexMonk-WMF renamed this task from Manage Templatedata tool should handle templatedata in subpage better to Manage Templatedata tool should handle transcluded templatedata better.Mar 26 2016, 6:07 PM
AlexMonk-WMF added a project: TemplateData.
Restricted Application added a project: VisualEditor. · View Herald TranscriptMar 26 2016, 6:07 PM
Jdforrester-WMF closed this task as Invalid.Mar 29 2016, 8:31 PM
Jdforrester-WMF added a subscriber: Jdforrester-WMF.

Clicking "manage tempaltedata" on template page gives no indication that tempatedata structure already exists in transcluded page, which is not good when someone does not realize it and creates templatedata in template page even though another already exists in subpage

Not true. Are you using a version from a very long time ago?

in the subpage, the tool loses the capability of automatically generating TD, and offering to add missing parameters

Not true. Same question.

Kipod added a comment.EditedApr 2 2016, 6:46 PM

Clicking "manage tempaltedata" on template page gives no indication that tempatedata structure already exists in transcluded page, which is not good when someone does not realize it and creates templatedata in template page even though another already exists in subpage

Not true. Are you using a version from a very long time ago?

in the subpage, the tool loses the capability of automatically generating TD, and offering to add missing parameters

Not true. Same question.

@Jdforrester-WMF : you either did not understand the bug report, or you do not know how the system actually works.
since the report was closed as "invalid" erroneously, i reopened it.
you can still reject it, but your "Not true" comments are not true.

so here goes:

REPRODUCTION INSTRUCTIONS

  1. open [[mw:Template:Test TD]]. notice tempaltedata structure. this is transcluded in this template from [[mw:Template:Test TD/Templatedata]].
  2. click "Edit source"
  3. click "Manage Templatedata"
  4. note that the editor does not contain any of the parameters you saw in step 1
  5. note that the tool does not indicate that there is "temapltedata" transcluded in the template from another page.
  6. note that the tool offers you to add a single parameter the template uses which is missing from TD, aptly named "not in td"
  7. do not save. clode the editor.
  8. open [[mw:Template:Test TD/Templatedata]].
  9. notice the tempaltedata structure - it's the same as the one you saw in step 1.
  10. "edit source" and "manage templatedata".
  11. notice that the editor fails to notice that the parameter "not in td" actually exists in the template and is missing from the templatedata structure.

for the last step: i understand that it can be hard, maybe even impossible for the tool to find the template transcluding this TD. this is why i asked to be able to *manually* tell the tool where is the "template page", when the TD reside in a different page.

peace.

Kipod reopened this task as Open.Apr 2 2016, 6:47 PM

Aha. When you said "structure already exists in transcluded page" you meant "already exists on a page which is transcluded onto this page" not "already exists on a page where this page is transcluded", which is the normal user editing pattern. Sorry. Will re-title.

Jdforrester-WMF renamed this task from Manage Templatedata tool should handle transcluded templatedata better to TemplateData warning that TD is defined on a sub-page should also show the other way around.Apr 3 2016, 8:27 AM
Jdforrester-WMF triaged this task as Lowest priority.
Jdforrester-WMF updated the task description. (Show Details)
Jdforrester-WMF moved this task from To Triage to Freezer on the VisualEditor board.
Kipod added a comment.Apr 3 2016, 5:18 PM

Aha. When you said "structure already exists in transcluded page" you meant "already exists on a page which is transcluded onto this page" not "already exists on a page where this page is transcluded", which is the normal user editing pattern. Sorry. Will re-title.

@Jdforrester-WMF : this may stem from english not being my first language, but i understand "transcluded page" as a page transcluded in the template page, and "transcluding page" as a page which transcludes the template.

also, you changed the synopsis to
"TemplateData warning that TD is defined on a sub-page should also show the other way around"

i have two issues with this:

  1. i do not see _any_ warning in either direction. clearly, you believe such warning appears. please supply clear instructions how to see this.
  2. the new synopsis completely ignores half of the actual request (steps 8-11 above). i will rephrase the synopsis again.

peace.

Kipod added a comment.EditedApr 3 2016, 5:27 PM

@Jdforrester-WMF :
i also noticed that you changed the original problem description to

We show "Please note: there is already a TemplateData block on the related page "Template:Foo/doc"." from Template:Foo, but not "Please note: there is already a TemplateData block on the related page "Template:Foo"." from Template:Foo/doc.

i have two issues here:

  • i cannot see the alleged warning, and TTBOMK such warning simply does not exist. please describe what should i do in order to see this warning
  • this covers only part of the original ticket.

i am restoring now my original description, with some rewording for brevity and clarity, the best i can. since you clearly did not understand the report and did not read it seriously, i'll assume that giving it "Lowest" priority was done by mistake. restoring it to "Normal" . i am aware that priority assignment is for "triage" process and not for the people reporting the bug, but since the "triager" clearly
did not understand the report, i reverted his change. i have no intention of fighting over it - if forrester insists not to handle it, it will remain unhandled.

a side note, not related to the actual bug report: i was very disappointed to see the dismissive attitude Forrester demonstrated here.

peace.

Kipod renamed this task from TemplateData warning that TD is defined on a sub-page should also show the other way around to "Manage TemplateData" does not handle transcluded templatedata correctly .Apr 3 2016, 6:09 PM
Kipod raised the priority of this task from Lowest to Normal.
Kipod updated the task description. (Show Details)