5

I'm using django i18n and I've been executed makemessages several times to include new phrases I marked for translation while I'm developing my app.

Recently, I realised there are some translation (not many) marked as:

#~ msgid "Location:"
#~ msgstr "Lugar:"

#~ msgid "Sector:"
#~ msgstr "Sector:"

I found those entries are duplicated, since in the file the correct translations are there too:

#: templates/userprofile.html:63
msgid "Location"
msgstr "Lugar:"

#: tiesport/userprofile.html:69
msgid "Sector"
msgstr "Sector:"

What does this '#~' mean?

kiril
  • 4,914
  • 1
  • 30
  • 40

1 Answers1

7

According to the Pology manual (section 2.5.3), those are obsolete entries:

The last, fourth category are obsolete messages, the messages which are not present in the source any more. All obsolete messages are grouped at the end of the merged PO file, and fully commented out by the #~ comment

I couldn't find that in the gettext documentation, but the Pology manual also claims that "[t]here is no formal specification of the PO format; instead, the related parts of the Gettext manual serve as its working definition".

Paulo Almeida
  • 7,803
  • 28
  • 36
  • Then, I don't see why they are marked as obsolete messages and at the same time marked as for translation. It's a bit strange... Thanks for the answer! – kiril Aug 29 '14 at 19:45
  • 1
    @kiril as the messages in the source code change over time, messages that are no longer used are migrated to "obsolete" -- you can remove them yourself without consequence. They are kept by `gettext` in case they can help inform translation of new messages, or if you might eventually bring those old messages back into the active source – MichaelChirico Jun 25 '20 at 12:28