Closed Bug 1311115 Opened 3 years ago Closed 3 years ago

c-c l10n repacks: Error: Multiple locales aren't supported

Categories

(Thunderbird :: Build Config, defect)

defect
Not set

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 52.0

People

(Reporter: aleth, Assigned: Fallen)

References

Details

(Keywords: regression)

Attachments

(1 file, 1 obsolete file)

/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/objdir-tb/_virtualenv/bin/python /builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/mozilla/toolkit/mozapps/installer/l10n-repack.py /builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/objdir-tb/dist/l10n-stage/thunderbird ../../dist/xpi-stage/locale-ko \
	extensions/{e2fda1a4-762b-4020-b5ad-a41df1933103}=../../dist/xpi-stage/lightning-ko \
	--non-resource defaults/messenger/mailViews.dat
Error: Multiple locales aren't supported
Traceback (most recent call last):
  File "/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/mozilla/toolkit/mozapps/installer/l10n-repack.py", line 60, in <module>
    main()
  File "/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/mozilla/toolkit/mozapps/installer/l10n-repack.py", line 56, in main
    non_resources=args.non_resource, non_chrome=NON_CHROME)
  File "/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/mozilla/python/mozbuild/mozpack/packager/l10n.py", line 250, in repack
    _repack(app_finder, l10n_finder, copier, formatter, non_chrome)
  File "/tools/python27/lib/python2.7/contextlib.py", line 24, in __exit__
    self.gen.next()
  File "/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/mozilla/python/mozbuild/mozpack/errors.py", line 131, in accumulate
    raise AccumulatedErrors()
mozpack.errors.AccumulatedErrors
make[1]: *** [repackage-zip] Error 1
make[1]: Leaving directory `/builds/slave/tb-c-cen-l64-l10n-ntly-0000000/build/comm-central/objdir-tb/mail/locales'
make: *** [repackage-zip-ko] Error 2
Is one source of the multiple locales:
calendar/timezones/Makefile.in
It doesn't seem to have any repackage code and using lightning-packager.mk probably won't work as the timezones.properties file currently doesn't sit in the right place for it
See Also: → 1311122
Attached patch Add gdata-provider to MOZ_PKG_EXTRAL10N (obsolete) β€” β€” Splinter Review
I think we should try this. gdata-provider certainly gets processed, both in the nightly and the beta logs. The difference between nightly and beta could be Bug 1310749, which now removes a locale line for gdata-provider which wasn't removed before. Unfortunately I don't know how to test this locally.
Attachment #8802302 - Flags: review?(madperson)
Assignee: nobody → aleth
Status: NEW → ASSIGNED
Attachment #8802302 - Flags: review?(madperson) → review?(philipp)
Alternatively to that patch, we could try commenting out https://dxr.mozilla.org/comm-central/source/mail/locales/Makefile.in#209 instead.
(In reply to aleth [:aleth] from comment #2)
> Created attachment 8802302 [details] [diff] [review]
> Add gdata-provider to MOZ_PKG_EXTRAL10N
> 
> I think we should try this. gdata-provider certainly gets processed, both in
> the nightly and the beta logs. The difference between nightly and beta could
> be Bug 1310749, which now removes a locale line for gdata-provider which
> wasn't removed before. Unfortunately I don't know how to test this locally.

For circumstancial evidence, comm-aurora mac repacks are already fixed now [1], and if comment 2 is correct, uplifting bug 1310749 will break them. 

[1] e.g. https://archive.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-18-12-19-48-comm-aurora-l10n/comm-aurora-macosx64-l10n-nightly-es-ES-bm85-build1-build5150.txt.gz
(In reply to aleth [:aleth] from comment #4)
> [1] e.g.
> https://archive.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-18-12-19-
> 48-comm-aurora-l10n/comm-aurora-macosx64-l10n-nightly-es-ES-bm85-build1-
> build5150.txt.gz

Bah, that link should have been 
https://archive.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-18-12-19-48-comm-aurora-l10n/comm-aurora-macosx64-l10n-nightly-dsb-bm82-build1-build5458.txt.gz

"fixed" is still a bit locale-dependent...
Comment on attachment 8802302 [details] [diff] [review]
Add gdata-provider to MOZ_PKG_EXTRAL10N

Just a quick drive by...
> MOZ_PKG_EXTRAL10N += extensions/{e2fda1a4-762b-4020-b5ad-a41df1933103}=$(DIST)/xpi-stage/lightning-$(AB_CD)
>+MOZ_PKG_EXTRAL10N += extensions/{a62ef8ec-5fdc-40c2-873c-223b8a6925cc}=$(DIST)/xpi-stage/gdata-provider-$(AB_CD)
Isn't the usual format:
MOZ_PKG_EXTRAL10N += \
                   extensions/{e2fda1a4-762b-4020-b5ad-a41df1933103}=$(DIST)/xpi-stage/lightning-$(AB_CD) \
                   extensions/{a62ef8ec-5fdc-40c2-873c-223b8a6925cc}=$(DIST)/xpi-stage/gdata-provider-$(AB_CD) \
                   $(NULL)
OK, so I uplifted Bug 1310749 to test comment 4.

Before, on c-a practically all Linux repacks were working: https://ftp.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-18-21-07-28-comm-aurora-l10n/
Mac repacks were either working or failing on 'get mar' (for unknown reasons): https://ftp.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-18-21-07-29-comm-aurora-l10n/

After, all Linux and Mac repacks on c-a show this bug:
https://ftp.mozilla.org/pub/thunderbird/nightly/2016/10/2016-10-19-00-51-08-comm-aurora-l10n/

So I think it's pretty clear we should go with some version of comment 2 or comment 3 here, and it's not to do with insufficient clobbering after all.
Flags: needinfo?(philipp)
https://hg.mozilla.org/comm-central/rev/d35a8fbca7a3d30676eadf1203baede4efd2077c
Bug 1311115 - Add gdata-provider to MOZ_PKG_EXTRAL10N. rs=philipp DONTBUILD
Blocks: 1310749
Keywords: regression
Flags: needinfo?(philipp)
The experiment didn't resolve the problem. Given that bug 1310749 prompted this bug, that points at an issue with repack-stage.
Attachment #8802302 - Attachment is obsolete: true
Attachment #8802302 - Flags: review?(philipp)
Attached patch Fix - v2 β€” β€” Splinter Review
Here is a patch that fixes it, because \D does not work on linux. I've also taken the liberty to use mach's compare-locales in Lightning.
Assignee: aleth → philipp
Attachment #8802577 - Flags: review?(aleth)
Comment on attachment 8802577 [details] [diff] [review]
Fix - v2

Review of attachment 8802577 [details] [diff] [review]:
-----------------------------------------------------------------

Good catch! Unix vs unix strikes again.

Good idea to use the in-tree compare-locales here as well.
Attachment #8802577 - Flags: review?(aleth) → review+
https://hg.mozilla.org/comm-central/rev/da5fe4ebcd7826eed28dce41618156194015dd1e

Hope this fixes it!
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 52.0
That did the trick!
https://hg.mozilla.org/releases/comm-aurora/rev/4f8a28482c91f8614c56c4a110495dfdc8ba2ac9
Bug 1311115 - c-c l10n repacks: Error: Multiple locales aren't supported. r=aleth a=bustage-fix
Unfortunately mac and windows are still broken, we assume due to strange grep versions that don't support this kind of thing. We went with https://hg.mozilla.org/comm-central/rev/b55be7abda35fbb5ec5809d8c28ee813b85eb454 for now, but may have to use more drastic measures. If we can assume egrep installed that would be another option, or we just go ballistic and use '^locale.*en-US' or even '^locale'.
https://hg.mozilla.org/releases/comm-aurora/rev/a26e9957ca2a9d1a56847c6ffe4f3cb871986e71
Bug 1311115 - c-c l10n repacks: Error: Multiple locales aren't supported - fix grep again. rs=aleth a=aleth
You need to log in before you can comment on or make changes to this bug.