Closed
Bug 1399057
Opened 7 years ago
Closed 7 years ago
[compare-locales] Optionally yield Sections and Comments from FluentParser.walk
Categories
(Localization Infrastructure and Tools :: compare-locales, defect)
Localization Infrastructure and Tools
compare-locales
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: stas, Assigned: stas)
References
Details
Attachments
(1 file)
When onlyEntities is False, FluentParser should yield non-Message entries too, such as Comments and Sections.
Comment hidden (mozreview-request) |
Assignee | ||
Comment 2•7 years ago
|
||
This bug requires a new version of python-fluent due to bug 1406342.
Assignee: nobody → stas
Comment 3•7 years ago
|
||
mozreview-review |
Comment on attachment 8915929 [details]
Bug 1399057 - Yield Sections and Comments from FluentParser.walk.
https://reviewboard.mozilla.org/r/187188/#review192246
This is basically good, but we'll need a way to require the fluent update. I think cutting another release of python-fluent is the best way for that. With that and the change to setup.py to require that update, r=me.
Attachment #8915929 -
Flags: review?(l10n) → review+
Assignee | ||
Comment 4•7 years ago
|
||
Thanks. I plan to release python-fluent 0.4.3 when bug 1397234 is fixed. it's already fixed in fluent.js so it's just a matter of porting it.
Comment hidden (obsolete) |
Comment hidden (obsolete) |
Comment hidden (mozreview-request) |
Assignee | ||
Comment 8•7 years ago
|
||
mozreview-review |
Comment on attachment 8915929 [details]
Bug 1399057 - Yield Sections and Comments from FluentParser.walk.
https://reviewboard.mozilla.org/r/187188/#review192666
::: compare_locales/tests/test_ftl.py:106
(Diff revisions 1 - 2)
> C
> ''')
>
> [abc] = list(self.parser)
> self.assertEqual(abc.key, 'abc')
> - self.assertEqual(abc.val, '\n A\n B\n C')
> + self.assertEqual(abc.val, ' A\n B\n C')
This is a fallout from bug 1397234 and I filed bug 1406880 to decide if it should be changed. For now I don't think it affects compare-locales much; it shouldn't block us from moving forward.
::: setup.py:48
(Diff revision 2)
> packages=['compare_locales', 'compare_locales.tests'],
> package_data={
> 'compare_locales.tests': ['data/*.properties', 'data/*.dtd']
> },
> install_requires=[
> - 'fluent>=0.4.2',
> + 'fluent==0.4.3',
The development of python-fluent is tightly connected to the needs of compare-locales these days and there might be small changes to the AST, the reported spans etc. between minor versions. Let's pin point the exact version of the dependency for now; we can relax this later on once everything stabilizes.
Assignee | ||
Comment 9•7 years ago
|
||
https://hg.mozilla.org/l10n/compare-locales/rev/72372d88d8fc3a83caf8dc24d7b50828b2f27d5b
Bug 1399057 - Yield Sections and Comments from FluentParser.walk. r=Pike
Assignee | ||
Updated•7 years ago
|
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•