← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~cjwatson/launchpad:py3-language-pack-script into launchpad:master

 

Colin Watson has proposed merging ~cjwatson/launchpad:py3-language-pack-script into launchpad:master.

Commit message:
Remove unnecessary encoding from language pack script

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/399006

Encoding these prevents them from working properly with os.path.join in Python 3.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:py3-language-pack-script into launchpad:master.
diff --git a/lib/lp/translations/scripts/language_pack.py b/lib/lp/translations/scripts/language_pack.py
index b71be13..0ef600f 100644
--- a/lib/lp/translations/scripts/language_pack.py
+++ b/lib/lp/translations/scripts/language_pack.py
@@ -131,8 +131,8 @@ def export(distroseries, component, update, force_utf8, logger):
                 # one.
                 gc.collect()
 
-        domain = potemplate.translation_domain.encode('ascii')
-        code = pofile.getFullLanguageCode().encode('UTF-8')
+        domain = potemplate.translation_domain
+        code = pofile.getFullLanguageCode()
         path = os.path.join(path_prefix, code, 'LC_MESSAGES', '%s.po' % domain)
 
         try: