This is mostly a correctness issue rarely seen in final PO files as
makemessages usually runs
the resulting PO file through additional invocations of gettext tools
which can correct the issue in case the plural forms formula PO header
line is the last one.
--
Ticket URL: <https://code.djangoproject.com/ticket/26670>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Old description:
> When it copieds the plural form formula header line from Django
> translations it can insert a line with a triling newline:
>
> https://github.com/django/django/blob/4731e9d82ea72b6d793fb06713d11d228eb89ace/django/core/management/commands/makemessages.py#L624
>
> This is mostly a correctness issue rarely seen in final PO files as
> makemessages usually runs
> the resulting PO file through additional invocations of gettext tools
> which can correct the issue in case the plural forms formula PO header
> line is the last one.
New description:
When it copies the plural form formula header line from Django
translations it can insert a line with a triling newline:
This is mostly a correctness issue rarely seen in final PO files as
makemessages usually runs
the resulting PO file through additional invocations of gettext tools
which can correct the issue in case the plural forms formula PO header
line is the last one.
--
--
Ticket URL: <https://code.djangoproject.com/ticket/26670#comment:1>
* owner: nobody => ramiro
* status: new => assigned
--
Ticket URL: <https://code.djangoproject.com/ticket/26670#comment:2>
* has_patch: 0 => 1
* stage: Unreviewed => Ready for checkin
Comment:
Fixed by [https://github.com/django/django/pull/6645 PR 6645] according to
the commit message there.
--
Ticket URL: <https://code.djangoproject.com/ticket/26670#comment:3>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"6ab0d1358fc78077064aab88a4fb0a47ca116391" 6ab0d13]:
{{{
#!CommitTicketReference repository=""
revision="6ab0d1358fc78077064aab88a4fb0a47ca116391"
Fixed #26645 -- Fixed potential makemessages failures on Windows.
This was reflected by 27 i18n test errors (not failures) on such
platform caused by corrupt intermediate PO catalog files fed to
`msgmerge(1)`.
Made it handle in-memory PO/POT file contents with normalized line
separators (`'\n'`).
We need to perform manually this after using `subprocess.Popen` as we
can't pass it `universal_newlines=True`.
Also fixes #26670 in the process as this commit refactors the same code
section.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/26670#comment:4>
Comment (by Tim Graham <timograham@…>):
In [changeset:"fc644076cdb45b8c227ff3041540f281a2c0b007" fc64407]:
{{{
#!CommitTicketReference repository=""
revision="fc644076cdb45b8c227ff3041540f281a2c0b007"
[1.10.x] Fixed #26645 -- Fixed potential makemessages failures on Windows.
This was reflected by 27 i18n test errors (not failures) on such
platform caused by corrupt intermediate PO catalog files fed to
`msgmerge(1)`.
Made it handle in-memory PO/POT file contents with normalized line
separators (`'\n'`).
We need to perform manually this after using `subprocess.Popen` as we
can't pass it `universal_newlines=True`.
Also fixes #26670 in the process as this commit refactors the same code
section.
Backport of 6ab0d1358fc78077064aab88a4fb0a47ca116391 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/26670#comment:5>