[open-ils-commits] r13542 - branches/rel_1_6/build/i18n/scripts (dbs)

svn at svn.open-ils.org svn at svn.open-ils.org
Wed Jul 8 22:14:30 EDT 2009


Author: dbs
Date: 2009-07-08 22:14:28 -0400 (Wed, 08 Jul 2009)
New Revision: 13542

Modified:
   branches/rel_1_6/build/i18n/scripts/db-seed-i18n.py
Log:
Merge 13541 from trunk: set explicit encoding for database i18n input

Modified: branches/rel_1_6/build/i18n/scripts/db-seed-i18n.py
===================================================================
--- branches/rel_1_6/build/i18n/scripts/db-seed-i18n.py	2009-07-09 02:13:05 UTC (rev 13541)
+++ branches/rel_1_6/build/i18n/scripts/db-seed-i18n.py	2009-07-09 02:14:28 UTC (rev 13542)
@@ -18,6 +18,7 @@
 # GNU General Public License for more details.
 
 import basel10n
+import codecs
 import optparse
 import polib
 import re
@@ -59,7 +60,7 @@
         serts = dict()
 
         # Iterate through the source SQL grabbing table names and l10n strings
-        sourcefile = open(source)
+        sourcefile = codecs.open(source, encoding='utf-8')
         for line in sourcefile:
             try:
                 num = num + 1



More information about the open-ils-commits mailing list