Last modified: 2014-08-06 17:30:51 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T65265, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 63265 - timestamp in Hebrew and possibly other languages must support more than singular and plural
timestamp in Hebrew and possibly other languages must support more than singu...
Status: NEW
Product: Wikipedia App
Classification: Unclassified
Localization/Translation/Language (Other open bugs)
Android (alpha)
All All
: Unprioritized normal
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-03-29 17:40 UTC by Amir E. Aharoni
Modified: 2014-08-06 17:30 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Amir E. Aharoni 2014-03-29 17:40:03 UTC
When the article was edited 2 days ago, the timestamp in Hebrew literally says "2 days ago" (לפני 2 ימים). It must support the dual number, where the number "2" is embedded in the word (יומיים). This is supported in MediaWiki and CLDR. It is needed for other languages - Arabic, Slovenian and possible others.
Comment 1 Brion Vibber 2014-07-01 15:09:04 UTC
Is this still an issue for Android? In theory multiple plural numbers should be supported...


Meanwhile looks like there's a couple ways to handle this on iOS:

First is to use a handy third-party library that maps the plural rules to separate messages: https://github.com/Smartling/ios-i18n

Second is to use a new extension in iOS 7, and leave some plurals 'broken' for iOS 6 users:
https://developer.apple.com/library/mac/releasenotes/Foundation/RN-Foundation/#//apple_ref/doc/uid/TP30000742-CH2-SW56

Either way we'll need to extend the Translate extension's AppleFFS module to convert to/from {{PLURAL:}} as used on TWN.


This last one probably maps best to MediaWiki-style {{PLURAL:}} coding in terms of being able to vary individual chunks of messages, but as it requires creating a separate .stringsdict file I'm not sure if that complicates the input/output processing beyond what the Translate FFS interface supports.

My inclination is to go with the second method for now; can use code similar to the AndroidXmlFFS module to flatten/unflatten translations using {{PLURAL:}} on single keys, and the extra messages just go in/out of the same .strings file we're already operating on.
Comment 2 Nemo 2014-07-05 10:27:06 UTC
> This is supported in MediaWiki
> and CLDR.

...not without problems, see bug 64430.
Comment 3 Amir E. Aharoni 2014-08-06 17:30:08 UTC
I talked about it to Yuvi at Wikimania.

The problem is that the app uses Android's time formatting, and it apparently doesn't support the dual for Hebrew, and possibly has problems in other languages as well.

There's another problem that arises from using this library, which is that when it has to use an actual date ("August 6"), the correct preposition is not used, because it cannot be translated in the message.

The possible solutions are:
1. To separate it to two or more messages for different cases (with and without human timestamps and maybe more).
2. To stop using human timestamps.
3. To develop Wikimedia's own human timestamps library.
4. Use JodaTime, although Yuvi doesn't know whether it is localized as well as moment.js.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links