Page MenuHomePhabricator

CX2: Outputs unnecessary self-closing nowiki and div tags inside ref tags
Closed, ResolvedPublic

Description

CX2 should not add unnecessary tags in ref tags :

  • The <nowiki/> tag should have been replaced by a whitespace character
  • The <div>...</div> tags are unnecessary and produce an incorrect rendering of the reference : the reference text is not displayed on the same line as the reference number (example with the 3rd reference)

Example on frwiki "Maaraue" : original translation with the following content

Example on frwiki "Claudia Pulchra" : original translation with the following content

  • <ref><div> Lightman, ''A à Z des femmes grecques et romaines anciennes'' , p.205 </div></ref>
  • <ref><div> Barrett, ''Agrippina: Sexe, pouvoir et politique dans le Premier Empire'' , p.78 </div></ref>
  • <ref><div> Lightman, ''A à Z des femmes grecques et romaines'' antiques, p.205; Barrett, ''Agrippina: Sexe, pouvoir et politique dans le Premier Empire'' , p.78 </div></ref>
  • ...

Related tickets:

Event Timeline

NicoV updated the task description. (Show Details)
NicoV updated the task description. (Show Details)

Change 486070 had a related patch set uploaded (by Santhosh; owner: Santhosh):
[mediawiki/services/cxserver@master] Avoid unnecessary <div> tags inside <ref> tags

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

Based on the example from this conversation, the translation of "Oktay Rıfat Horozcu" from English to Spanish has another example of unexpected <div> added for reference [2] (on the 3rd paragraph of the "Career" section).

If other samples are wanted, you can see the ones corrected on frwiki https://quarry.wmflabs.org/query/32900

If other samples are wanted, you can see the ones corrected on frwiki https://quarry.wmflabs.org/query/32900

Thanks @Framawiki! This is really useful, and will allow us to see the impact of the improvements we are working on.
I made a fork of the query to count the number of issues on a monthly basis.

If other samples are wanted, you can see the ones corrected on frwiki https://quarry.wmflabs.org/query/32900

According to the query, the last entry is from January 26. So it is possible that after the recent updates, the issues that the bot as fixing are no longer happening.

Change 486070 merged by jenkins-bot:
[mediawiki/services/cxserver@master] Avoid unnecessary <div> tags inside <ref> tags

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

Mentioned in SAL (#wikimedia-operations) [2019-02-11T03:00:58Z] <kartik@deploy1001> Started deploy [cxserver/deploy@ee4a15a]: Update cxserver to 8928852 (T213256)

Mentioned in SAL (#wikimedia-operations) [2019-02-11T03:05:06Z] <kartik@deploy1001> Finished deploy [cxserver/deploy@ee4a15a]: Update cxserver to 8928852 (T213256) (duration: 04m 08s)

If other samples are wanted, you can see the ones corrected on frwiki https://quarry.wmflabs.org/query/32900

According to the query, the last entry is from January 26. So it is possible that after the recent updates, the issues that the bot as fixing are no longer happening.

Note that quarry queries needs to be run manually by query owner, or by anyone after a fork. Results that are shown correspond to the results at the time it was executed, and is not updated automatically. Related upstream bug is T203791: Allow quarry queries to be executed by someone else without the need to fork. I've re-executed just now this query, that shows recent (last night) related entries.

Note that quarry queries needs to be run manually by query owner, or by anyone after a fork.

Thanks for the clarification. I created my own fork to be able to access to live data more easily. Since this particular ticket is about empty divs in references and it got deployed yesterday, I expect the instances of "div inutile dans une ref" to reduce over time (those should not happen with newly started translations but may appear in translations that were started earlier but not published immediately).

Etonkovidova subscribed.
  • I checked the problematic translations mentioned in the task en:Antonio Brunetti ->fr and de:Maaraue ->fr. In cx2-teseting div tags were not added anymore.
  • https://quarry.wmflabs.org/query/32917 -- shows a noticeable increase in corrections
  • https://gerrit.wikimedia.org/r/#/c/mediawiki/services/cxserver/+/486070/ -- I do not see deployment tag added to it. Will the fix be swatted?
  • <nowiki/> I did not see it added in the translations reported in the ticket, but I see it added when translating in cx2-testing (the addition was correctly done, in my opinion).

Note: the ticket is Resolved but I am not moving it to Done yet - it needs to be monitored in production.

Arrbee subscribed.

Note: the ticket is Resolved but I am not moving it to Done yet - it needs to be monitored in production.

Instead, re-opened and moved to Done to maintain visibility to ensure monitoring in production.

Pginer-WMF closed this task as Resolved.EditedMar 4 2019, 10:05 AM

I think we can close this one. Recent queries shown that bot fixes for this particular error are not appearing recently. It is still possible that a few old translations get published with these errors, but it seems that the issue is not happening for new translations. I created a customized version of the query to count the "div inutile dans une ref" case, and it shows 0 results for March (more than 2 issues/day were registered for previous months).

I'm closing the ticket. @NicoV, let us know if this also seems to be fixed from your perspective.

It seems to be ok on the last edits I checked, thansk

It seems to be ok on the last edits I checked, thansk

Great. Thanks for checking!