Page MenuHomePhabricator

Add gender support to Multimediaviewer-text-embed-credit-text-tbls
Closed, DeclinedPublic

Description

Multimediaviewer-text-embed-credit-text-tbls

Check other potentailly affected Multimediaviewer-text-embed-credit-* keys as well.

Requested at https://translatewiki.net/wiki/Thread:Support/About_MediaWiki:Multimediaviewer-text-embed-credit-text-tbls/el

Contributors please see https://www.mediawiki.org/wiki/Localisation#.E2.80.A6on_user_names_via_GENDER and the links in that section. For general info (not specific for this task, like providing a patch in Gerrit) please see https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker#Get_started

Event Timeline

Tgr created this task.Jan 2 2015, 6:41 AM
Tgr updated the task description. (Show Details)
Tgr raised the priority of this task from to Needs Triage.
Tgr added projects: MediaViewer, Multimedia.
Tgr added subscribers: Tgr, geraki.
Tgr updated the task description. (Show Details)Jan 2 2015, 8:02 AM
Tgr added a project: I18n.
Tgr set Security to None.

Hi Tgr i am new to wikimedia and phabricator . I want to contribute on this so can u guide me through this issue how to proceed?

Hi Surabhi_13692. Thanks! Please see https://www.mediawiki.org/wiki/Localisation#.E2.80.A6on_user_names_via_GENDER and the links in that section. For general info (not specific for this task, like providing a patch) please see https://www.mediawiki.org/wiki/How_to_become_a_MediaWiki_hacker#Get_started

Jdforrester-WMF triaged this task as Low priority.Sep 4 2015, 6:56 PM
Restricted Application added a subscriber: Matanya. · View Herald TranscriptSep 4 2015, 6:56 PM
Jdforrester-WMF moved this task from Untriaged to Backlog on the Multimedia board.Sep 4 2015, 7:03 PM
Devirk added a subscriber: Devirk.Sep 20 2015, 6:01 PM

Mass-removing the Multimedia tag from MediaViewer tasks, as this is now being worked on by the Reading department, not Editing's Multimedia team.

Devirk claimed this task.Sep 24 2015, 5:22 PM

@Devirk did you have a go at solving this task? If not I'd like to add it to Google-Code-In-2015

Aklapper removed Devirk as the assignee of this task.Dec 14 2015, 10:35 PM

No reply, hence unassigning.

Aklapper updated the task description. (Show Details)Dec 16 2015, 1:41 PM
MtDu added a subscriber: MtDu.Dec 18 2015, 3:42 PM

Hi,
I am having trouble understanding what exactly there is to add GENDER support for. The message is "multimediaviewer-text-embed-credit-text-tbls": "\"$1\" by $2. Licensed under $3 via $4". The only verb here is licensed, but isn't that referring to the picture?
Thanks,
MtDu

The message is "multimediaviewer-text-embed-credit-text-tbls": "\"$1\" by $2. Licensed under $3 via $4". The only verb here is licensed, but isn't that referring to the picture?

Keep in mind that different languages have different systems of declension and may need to inflect multiple parts of speech.

MtDu added a comment.EditedDec 18 2015, 6:46 PM

@Ricordisamoa,

Right. But isn't the subject of licensed the picture? So would that still have a GENDER?

Thanks,
MtDu

But isn't the subject of licensed the picture?

AFAICT from https://translatewiki.net/wiki/Thread:Support/About_MediaWiki:Multimediaviewer-text-embed-credit-text-tbls/el, the parameter in need of GENDER is $2, "name of the author".

Tgr added a comment.Dec 18 2015, 7:21 PM

The gender of $2 is needed, see the linked conversation. (The Greek translation has a definite article before $2, which has different forms depending on the gender of the noun it precedes.)

We cannot do that in a generic way since the author is just an arbitrary string. What could be done is to check if the name of the author equals the name of the uploader (possibly after stripping the formatting), in which case the gender of the user can be used.

(Although the logic would probably be removed in T59308. Sorry, poor planning on my behalf :( )

Tgr added a comment.Dec 18 2015, 10:01 PM

Discussed on IRC, but for the record:

  • author and uploader might or might not be the same person; also, uploader is a wiki username, author is a piece of HTML (typically the username inside an <a> tag which links to the userpage) so it needs to be normalized for comparison
  • if they are not the same person, the gender should be unspecified
  • mw.HtmlUtils.js has helper functions for stripping HTML formatting from text
  • needGender() in mmv.js will have to be updated (we need an extra API request to fetch the gender of the user and we try to avoid doing that if the translation does not actually depend on it)
  • you don't need to worry about the details of how gender is used; as long as it is passed as a parameter and {{GENDER}} is used somewhere in the English message translator will be able to use the functionality
  • the patch should add some QUnit tests for the new functionality

Change 260221 had a related patch set uploaded (by MtDu):
[WIP]Add gender support to Multimediaviewer-text-embed-credit-text-tbls and other messages

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

Change 260225 had a related patch set uploaded (by MtDu):
[WIP]Add gender support to Multimediaviewer-text-embed-credit-text-tbls and other related messages

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

MtDu added a comment.Dec 20 2015, 5:12 AM

Disregard https://gerrit.wikimedia.org/r/260225. Something weird happened when I tried to push another patch to https://gerrit.wikimedia.org/r/260221. Pay attention to https://gerrit.wikimedia.org/r/260221 please.
Thanks,
MtDu

Change 260225 abandoned by MtDu:
[WIP]Add gender support to Multimediaviewer-text-embed-credit-text-tbls and other related messages

Reason:
https://gerrit.wikimedia.org/r/#/c/260221/ is the right one. Something weird happened. Sorry for the confusion.
MtDu

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

Copied from patch:
Looking at this patch and thanks to the work that you've done in exploring this problem it's clear that it's not quite as simple as we first expected.
You've shown that there is lot of a code needed to solve this problem and given we run this for every user, it's potentially overly complex.
On this basis, I don't think we should merge this patch, as it points to deficiencies in our core project. However, I will accept your task as your work has helped us uncover these issues.

Change 260221 abandoned by Gergő Tisza:
Add gender support to Multimediaviewer-text-embed-credit-text-tbls and other messages

Reason:
I concur with Jon. Sorry MtDu, this task really got out of hand. It's pretty close to working now, but the value it would add cannot justify all the complexity it would bring in (especially given that most of the time it wouldn't help anyway because the author would not match the uploader).

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

Tgr closed this task as Declined.Dec 23 2015, 9:29 PM
Tgr claimed this task.
Restricted Application removed a subscriber: Liuxinyu970226. · View Herald TranscriptDec 23 2015, 9:29 PM
Restricted Application added a project: Multimedia. · View Herald TranscriptNov 15 2017, 8:08 PM