#28773: manage.py makemessages throws syntax error due to incorrectly generated
django.pot
-------------------------------------+-------------------------------------
Reporter: Hendy Irawan | Owner: nobody
Type: Bug | Status: new
Component: | Version: 1.11
Internationalization |
Severity: Normal | Resolution:
Keywords: gettext, | Triage Stage:
makemessages, Windows | Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Hendy Irawan):
Replying to [comment:10 Claude Paroz]:
> > Even if this is eventually fixed by msguniq, it will take some time.
> >
> > In the meantime, can I request Django provide a workaround by always
writing the pot file using LF EOL?
>
> We could, but could that be a problem for some Windows app to display
the file content properly?
AFAIK, the *only* program that can't manipulate LF files properly is
Notepad. I don't know any programmer who uses Notepad to edit code (even
for txt files, a lot of programmers I know use Notepad++ by default).
Any reasonable text editor that a Python programmer uses can edit LF files
without issue (and they usually have other gimmicks like syntax
highlighting, etc.), namely Notepad++, VSCode, PyCharm, Eclipse, etc.
Considering the two alternatives: (1) broken makemessages regardless of
what text editor you use, (2) working makemessages. I definitely vote for
LF-only.
When gettext finally fixes this (probably will take a while) we can revert
this workaround.
Another thing is that what matters is the *input* to gettext tools need to
be LF. I think the .po files (output which is editable by user) themselves
can still be CRLF (and I believe that's the default for gettext for
Windows). What matters is that django needs to ensure that whatever gets
processed by gettext needs to be forced first to LF.
--
Ticket URL: <https://code.djangoproject.com/ticket/28773#comment:11>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/065.5b8ea2cee14472e2d8e6026ceb97d9c4%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.