Closed Bug 1147332 Opened 9 years ago Closed 9 years ago

Multilocale build is broken: empty lockscreen, missing time in status bar, untranslated icons in homescreen

Categories

(Firefox OS Graveyard :: Gaia::Build, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: flod, Unassigned)

References

Details

Attachments

(3 files)

Attached image Lockscreen
Starting from Gaia::L10n, not sure if there's a better place to move it.

The multilocale build is basically broken all over the place. I flashed my own build on the phone with this command

make clean && PRODUCTION=1 make install-gaia MAKECMDGOALS=production MOZILLA_OFFICIAL=1 GAIA_DEFAULT_LOCALE=it GAIA_KEYBOARD_LAYOUTS=en,it LOCALES_FILE=../languages_all.json LOCALE_BASEDIR=locales/ DEVICE_DEBUG=1

../languages_all.json is a modified JSON version with only Italian and English.

When I restart the phone:
* the lockscreen is completely empty, I see only the operator name. If I switch to English it looks normal
* Social, Games, Music icons have English names
* Time is missing from the status bar.

Right now the lockscreen, after switching to English and then back to Italian, is showing some text in English (even the dialer).
Attached file log.txt
The log is full of errors like

[multilocale] Resource file not found: /shared/locales/date/date.en-US.properties
[multilocale] Resource file not found: /shared/date/date.properties
Zibi, are you aware of any change that might have cause this?
Flags: needinfo?(gandalf)
Also sub-apps in /communications are not localized (e.g. Contacts)

[multilocale] Resource file not found: /contacts/locales/contacts.en-US.properties
[multilocale] Resource file not found: /contacts/contacts.properties
Info on the device

Build ID               20150325010206
Gaia Revision          a8256b632f571b2ed45129213490e14a86e15c7f
Gaia Date              2015-03-25 09:44:21
Gecko Revision         https://hg.mozilla.org/mozilla-central/rev/cc0950b7a369
Gecko Version          39.0a1
Device Name            flame
Firmware(Release)      4.4.2
Firmware(Incremental)  39
Firmware Date          Thu Oct 16 18:19:14 CST 2014
Bootloader             L1TC00011880
T(In reply to Francesco Lodolo [:flod] (UTC+1) from comment #0)
> Created attachment 8583017 [details]
> Lockscreen
> 
> Starting from Gaia::L10n, not sure if there's a better place to move it.
> 
> The multilocale build is basically broken all over the place. I flashed my
> own build on the phone with this command

Somewhat similar on my build.

> 
> make clean && PRODUCTION=1 make install-gaia MAKECMDGOALS=production
> MOZILLA_OFFICIAL=1 GAIA_DEFAULT_LOCALE=it GAIA_KEYBOARD_LAYOUTS=en,it
> LOCALES_FILE=../languages_all.json LOCALE_BASEDIR=locales/ DEVICE_DEBUG=1
> 
> ../languages_all.json is a modified JSON version with only Italian and
> English.
> 
> When I restart the phone:
> * the lockscreen is completely empty, I see only the operator name. If I
> switch to English it looks normal

French locale, I see the time and the date but in English.

> * Social, Games, Music icons have English names

Same here.

> * Time is missing from the status bar.

I'm not sure this is related, I have this since a long time.

> 
> Right now the lockscreen, after switching to English and then back to
> Italian, is showing some text in English (even the dialer).
(In reply to Alexandre LISSY :gerard-majax from comment #5)
> > When I restart the phone:
> > * the lockscreen is completely empty, I see only the operator name. If I
> > switch to English it looks normal
> 
> French locale, I see the time and the date but in English.

I flashed from pvt, after restarting the phone I had the entire screen in English.
Then I flashed my own build, and got an empty screen after restart.
I think I can reproduce your problem, but a short video demonstrating the behavior would help.

I also don't know what could cause it and I'm not sure if it's a build issue or runtime issue.

Keeping NI on myself
I was able to reproduce it with a simpler command:

APP=system make profile LOCALES_FILE=./locales/languages_my.json LOCALE_BASEDIR=../gaia-l10n/master/

where languages_my.json contains en-US and fr and ../gaia-l10n/master/fr is a current gaia-l10n repo for fr.

My first suspect is bug 1131515 which is the last change to multilocale.js
Thanks, let's see if the assignee of that bug has some ideas.

Should we also move to Gaia::Build, since it doesn't seem related on Gaia::L10n?
Flags: needinfo?(gduan)
Yes.
Component: Gaia::L10n → Gaia::Build
Flags: needinfo?(gandalf)
I confirmed that it is that bug. I provided more details there.
Actually, there's more. Bug 1131515 makes the multilocale build time script not pick up the right files, but even when the locale files are copied properly and merged into JSON, we still have missing strings, for example Settings uses en-US strings instead of fr strings after bug 1037962 landed (bisected it) - but I don't understand how that bug could affect it so I suspect a red herring.

Once we fix the regression in the build system we'll be able to track down the runtime one.
Next update. It seems that GAIA_DEFAULT_LOCALE is breaking things for runtime. After reverting the build system patch, I can build Gaia with fr locale and switch to it. But building with GAIA_DEFAULT_LOCALE=fr breaks things.
Ok, sequence:

 - build with GAIA_DEFAULT_LOCALE=fr // broken
 - switch to en-US // works
 - switch back to fr // broken

the only thing I noticed so far is that most apps work, Settings and Lockscreen don't. In Settings the *.json object looks good, but navigator.mozL10n.ctx.locales.fr.entries has only 41 entries.
(In reply to Zibi Braniecki [:gandalf][:zibi] from comment #14)
> Ok, sequence:
> 
>  - build with GAIA_DEFAULT_LOCALE=fr // broken
>  - switch to en-US // works
>  - switch back to fr // broken
> 
> the only thing I noticed so far is that most apps work, Settings and
> Lockscreen don't. In Settings the *.json object looks good, but
> navigator.mozL10n.ctx.locales.fr.entries has only 41 entries.

And that seems to be an already known issue for the GAIA_DEFAULT_LOCALE flag: bug 1135199
Depends on: 1135199
Ok. I'm fairly confident that we're facing those two problems now:

 - build time regression from bug 1131515
 - GAIA_DEFAULT_LOCALE regression as tracked in bug 1135199

I'm trying to debug bug 1135199 and bisect is sending me in circles :(
Comment on attachment 8583569 [details] [review]
[gaia] cctuan:1147332 > mozilla-b2g:master

Hi Zibi,
I tried comment 0's command with this patch and it works fine, could you help me to review it? Thanks, We'll need to file a new bug to fix joinPath api in utils-xpc.js.
Flags: needinfo?(gduan)
Attachment #8583569 - Flags: review?(gandalf)
Comment on attachment 8583569 [details] [review]
[gaia] cctuan:1147332 > mozilla-b2g:master

r+

> We'll need to file a new bug to fix joinPath api in utils-xpc.js.

Can you file it?
Attachment #8583569 - Flags: review?(gandalf) → review+
Thanks,
https://github.com/mozilla-b2g/gaia/commit/ae510d4971d8ddf7b1a48186f692e59a2217733b

File bug 1147970 for utils.joinPath.apply(null, paths)
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: