[damned-lies] Apply previous fix to other lines



commit 5b34185e820e94bd27b02d6f6f84a0a230deb0e9
Author: Claude Paroz <claude 2xlibre net>
Date:   Wed May 29 21:28:51 2019 +0200

    Apply previous fix to other lines

 vertimus/views.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/vertimus/views.py b/vertimus/views.py
index 9f9fc3b1..502b0776 100644
--- a/vertimus/views.py
+++ b/vertimus/views.py
@@ -351,7 +351,8 @@ class BuildTranslatedDocsView(PoFileActionBase):
             ], cwd=str(doc_format.vcs_path), stderr=subprocess.PIPE)
             if result.returncode != 0:
                 return build_error % {
-                    'program': 'itstool', 'err': result.stderr.decode()
+                    'program': 'itstool',
+                    'err': result.stderr.decode(errors='replace'),
                 }
 
             # Now build the html version
@@ -372,7 +373,8 @@ class BuildTranslatedDocsView(PoFileActionBase):
             if result.returncode != 0 or (not index_html.exists() and len(result.stderr)):
                 shutil.rmtree(str(html_dir))
                 return build_error % {
-                    'program': 'yelp-build', 'err': result.stderr.decode()
+                    'program': 'yelp-build',
+                    'err': result.stderr.decode(errors='replace'),
                 }
 
             if not index_html.exists() and os.path.isfile(build_ref[0]):


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]