﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
21963	makemessages still ignores translations in templates with inline comment tags	Ihor Kaharlichenko <madkinder@…>	Sergey Kolosov	"This bug is claimed to be fixed in #19552, though it's not.

Here's the test case:

Template:

{{{#!django
{% load i18n %}
 
{# Translators: Abbreviated month name #}
{% trans ""Jan"" %}
 
{# Translators: Abbreviated month name #}{% trans ""Feb"" %}
 
{% comment %}Translators: Abbreviated month name{% endcomment %}{% trans ""Mar"" %}
 
{# Translators: Abbreviated month name #} {% trans ""Apr"" %}
 
{% comment %}Translators: Abbreviated month name{% endcomment %} {% trans ""May"" %}

{# Translators: Abbreviated month name #}
{% trans ""Jun"" %}

{# Translators: Abbreviated month name #}

{% trans ""Jul"" %}

{% comment %}Translators: Abbreviated month name{% endcomment %}

{% trans ""Aug"" %}
}}}

The extraction session:

{{{
$ ./manage.py version
1.6.1
$ ./manage.py makemessages -l ru -i venv
.../trans_real.py:585: TranslatorCommentWarning: The translator-targeted comment 'Translators: Abbreviated month name' (file app1/templates/i18n_test.html, line 6) was ignored, because it wasn't the last item on the line.
  warnings.warn(warn_msg, TranslatorCommentWarning)

.../trans_real.py:585: TranslatorCommentWarning: The translator-targeted comment 'Translators: Abbreviated month name' (file app1/templates/i18n_test.html, line 10) was ignored, because it wasn't the last item on the line.
  warnings.warn(warn_msg, TranslatorCommentWarning)

processing locale ru
}}}

Resulting po file:

{{{#!po
#. Translators: Abbreviated month name
#: app1/templates/i18n_test.html:4
msgid ""Jan""
msgstr """"

#: app1/templates/i18n_test.html:6
msgid ""Feb""
msgstr """"

#. Translators: Abbreviated month name gettext(u'Mar')
#: app1/templates/i18n_test.html:10
msgid ""Apr""
msgstr """"

#. Translators: Abbreviated month name  gettext(u'May')
#. Translators: Abbreviated month name
#: app1/templates/i18n_test.html:15
msgid ""Jun""
msgstr """"

#. Translators: Abbreviated month name
#: app1/templates/i18n_test.html:19
msgid ""Jul""
msgstr """"

#. Translators: Abbreviated month name
#: app1/templates/i18n_test.html:23
msgid ""Aug""
msgstr """"
}}}

The problems:
* translations for ""Mar"" and ""May"" were completely skipped
* there was a warning for single-tag comments (for Feb and Apr), but not for block comments (for Mar and May), which is inconsistent
* Apr and Jun got wrong comments"	Bug	assigned	Internationalization	1.6	Normal		makemessages, template, gettext, xgettext	madkinder@…	Accepted	1	0	0	1	0	0
