← Back to team overview

ubuntu-translations-coordinators team mailing list archive

[Bug 1327419] Re: Infographic's language not updated until the metric value is changed

 

I've attached a branch that allows the infographics to read translations
from click packages in addition to the standard language packs.

I've confirmed that this works.

However, the translations for the music app infographics need updating.
In its codebase it actually pre-translates the strings before it sends
them to the infographics server. What it *should* be doing is tagging
the strings from translation, but not translating them itself. Usually
you can do this with a dummy pass-through function as below:

    function translateMe(s) {
        return s;
    }

    Metric {
        id: songsMetric
        name: "music-metrics"
        format: translateMe("Songs played today: <b>%1</b>")
        emptyFormat: translateMe("No songs played today")
        domain: "com.ubuntu.music"
    }

and then configure gettext to extract this function.

-- 
You received this bug notification because you are a member of Ubuntu
Translations Coordinators, which is subscribed to Ubuntu Translations.
Matching subscriptions: Ubuntu Translations bug mail
https://bugs.launchpad.net/bugs/1327419

Title:
  Infographic's language not updated until the metric value is changed

Status in the base for Ubuntu mobile products:
  Confirmed
Status in Music application for Ubuntu devices:
  New
Status in Ubuntu Translations:
  Triaged
Status in libusermetrics package in Ubuntu:
  In Progress

Bug description:
  1) Start the music app
  2) Play a track for more than 10 seconds to trigger the metric update
  3) Lock and unlock to show the infographic
  4) Note, for example, "1 song played today" appears (double tap to cycle through to find music if required)
  5) Goto system settings and change the language
  6) Restart the device
  7) Note the infographic's language has not been updated and it still states '1 song played today'
  8) Start the music app
  9) Play a track for more than 10 seconds to trigger the metric update
  10) Lock and unlock to show the infographic
  11) Now notice the infographic's language is now correct, for example "2 Morceaux joues aujourd'hui"

  It was expected that step 7 the infographic would show the correct
  language.

To manage notifications about this bug go to:
https://bugs.launchpad.net/canonical-devices-system-image/+bug/1327419/+subscriptions