Malformed install.rdf for Catalan xpi in Firefox 18

RESOLVED FIXED

Status

Mozilla Localizations
ca / Catalan
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: Chris Coulson, Assigned: Eduard Gamonal)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

736 bytes, application/rdf+xml
Details
(Reporter)

Description

4 years ago
Created attachment 700641 [details]
Catalan install.rdf

The Catalan language pack xpi for Firefox 18 has a malformed install.rdf. There are 2 lines of whitespace at the start of the file (attached), which results in the addon manager not loading it.

It's caused by this change: http://hg.mozilla.org/releases/l10n/mozilla-release/ca/diff/3b0b37ceb8b0/browser/defines.inc
(Reporter)

Updated

4 years ago

Comment 1

4 years ago
Mmm, this was caused by applying patch from bug 792717 I suppose.

We can try to add it back to all defines.inc in different branches.

Ccing Gerv as well.
None of the 3 patches attached to bug 792717 patch a file called defines.inc. And the changes in those patches are not missing newlines, which it seems this change was. Perhaps it was done by hand by someone?

Gerv
Duplicate of this bug: 829955
(Reporter)

Comment 4

4 years ago
Arabic has exactly the same problem too - see bug 828151

http://hg.mozilla.org/releases/l10n/mozilla-release/ar/file/497a26f71f69/browser/defines.inc
(Reporter)

Comment 5

4 years ago
A quick grep shows up some more affected locales too:

chr1s@farnsworth:~/src/firefox/build-area/firefox-18.0+build1$ grep '^.\+#filter emptyLines' l10n/*/browser/defines.inc
l10n/ar/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/bn-BD/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/ca/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/fa/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/ff/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/gd/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
l10n/nso/browser/defines.inc:# This Source Code Form is subject to the terms of the Mozilla Public# License, v. 2.0. If a copy of the MPL was not distributed with this# file, You can obtain one at http://mozilla.org/MPL/2.0/.#filter emptyLines
Dwayne, can this be a bug in the translate toolkit handling of .inc files?

Comment 7

4 years ago
@Axel, almost definitely the bug fixed by https://github.com/translate/translate/commit/e0d8001989dcf891976df8bb4e17cf9c68f85a9e

@Toni using Toolkit from master or the 1.10.0.RC1 release from http://translate.sourceforge.net/snapshots/ will solve this for you.

I only spotted the bug after struggling to get Samoan language packs to build from, I think, earlier then 18. Since most people don't/can't install the language pack I was hoping the issue would just filter its way out as the release train got rid of those broken language packs.  So unfortunately I didn't audit the .inc files that had gone before the discovery.

The fix is quite obvious so could be easy to role out.  Would be nice to know if there are any remaining in Beta. Not sure what happens on release though i.e. if it is needed/easy to deploy such a fix.

Comment 8

4 years ago
Thanks Dwaine! I've upgraded translate-toolkit in the server where we host our translations.

Eduard will fix defines.inc in aurora, beta and release branches.
(Assignee)

Comment 9

4 years ago
I checked the defines.inc file in en_GB, fr and it and took them as an example to fix our files. 
changesets:
* aurora http://hg.mozilla.org/releases/l10n/mozilla-aurora/ca/rev/efde863f1e8d
* beta http://hg.mozilla.org/releases/l10n/mozilla-beta/ca/rev/3dbaa6ad48c4 and http://hg.mozilla.org/releases/l10n/mozilla-beta/ca/rev/64a556f3e8e1
* release http://hg.mozilla.org/releases/l10n/mozilla-release/ca/rev/dcaee0efd771

I don't know how to test it.
Sorry, but these patches don't do what's expected.

browser/defines.inc should look like this, with no leading whitespace:

# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#filter emptyLines

#define MOZ_LANGPACK_CREATOR Mozilla.org / SoftcatalĂ 

# If non-English locales wish to credit multiple contributors, uncomment this
# variable definition and use the format specified.
#define MOZ_LANGPACK_CONTRIBUTORS <em:contributor>SoftcatalĂ </em:contributor>

#unfilter emptyLines

Does that make sense or would you rather have someone else provide a patch?
(Assignee)

Comment 11

4 years ago
Hi Axel,
I took en_GB and fr as an example and it didn't work. Maybe it's faster and safer if somebody more experienced provides a patch.
Thanks

Comment 12

4 years ago
I've signed off in Dashboard. I assume that builds were not taking last Edu's changes. We're affecting too much users here! :(
Please, accept anyway, Axel. It's not working anyway right now (and we need to test it's not happening in beta). We can sign off more later.

Edu, you have missed .'#filter emptyLines' attached to the license string. Moreover, Axel is suggesting that the order of license info and filter should be the reverse. Overall situation now is not cute, but I think it should not be affecting the outcome and I'd dare to say that XPI should be valid with this patch applied.

Comment 13

4 years ago
Fixed anyway now.
http://hg.mozilla.org/releases/l10n/mozilla-beta/ca/rev/717fbb282204
http://hg.mozilla.org/releases/l10n/mozilla-beta/ca/rev/09d35d80bae1

Let's cross fingers for next beta.

Comment 14

4 years ago
We've missed 19.0b4. It's not working yet.

Updated

4 years ago
Duplicate of this bug: 828151

Comment 16

4 years ago
19.0b5 seems to work fine :)
I guess it's unlikely there will be a 18.0.3:
http://hg.mozilla.org/releases/l10n/mozilla-release/ca
Status: NEW → ASSIGNED

Comment 17

4 years ago
I change it as fixed. Reopen if something may still be done with 18 branch.
Status: ASSIGNED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.