Closed
Bug 1414116
Opened 8 years ago
Closed 8 years ago
Pontoon shouldn’t import files outside of /locales or /templates
Categories
(Webtools Graveyard :: Pontoon, enhancement)
Webtools Graveyard
Pontoon
Tracking
(Not tracked)
RESOLVED
INVALID
People
(Reporter: theo, Unassigned)
Details
When the Buyer’s Guide files got merged into master, Pontoon imported into Mozilla Advocacy project the .properties files that we specifically put in a random folder, well away from /locales: https://github.com/mozilla/advocacy.mozilla.org/tree/master/buyers-guide-locales
Not sure if this happened because the folder contains "locales" in its name, but if I correctly understood what Matjaz told me, Pontoon wasn’t supposed to even look in that folder.
| Reporter | ||
Comment 1•8 years ago
|
||
Note: I’ve temporarily disabled the Mozilla Advocacy project, until this bug is fixed
Comment 2•8 years ago
|
||
Here's how detecting localizable files work:
Pontoon walks the directory tree and looks for folders named "templates", "en-US", "en-us" or "en" that contain localizable files in a supported file format. The first folder that meets the criteria is treated as source folder and all its sibling folders named as locale codes are treated as locale folders.
Everything else is ignored. So if multiple folders meet the criteria for a source folder, only the first one is used. That's what happened in your case and caused the Buyer’s Guide files to be imported into Pontoon.
Note that the "locales" folder doesn't get any special treatment, it could also be called "bla" or not exist at all (e.g. https://github.com/mozilla-l10n/www.mozilla.org).
I've updated the docs to make that clearer:
https://developer.mozilla.org/en-US/docs/Mozilla/Implementing_Pontoon_in_a_Mozilla_website
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Comment 3•8 years ago
|
||
The real fix is going to be project config, which is bug 1385834.
Updated•4 years ago
|
Product: Webtools → Webtools Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•