From 09da55e90f5d5d15a893b0e091145b64897112f5 Mon Sep 17 00:00:00 2001 From: GeneGH Date: Thu, 7 Feb 2019 17:19:57 -0500 Subject: [PATCH] Repair pythonopen in line 126 for Python3 Python 3 is fussy about match of data type for a file open or write. Python 2 does not seem to care if a string is written with a 'wb' indicating a binary type, but Python 3 flags it as an error. --- src/Mod/Arch/importWebGL.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Mod/Arch/importWebGL.py b/src/Mod/Arch/importWebGL.py index 0ac366c41c..d05948fcf6 100644 --- a/src/Mod/Arch/importWebGL.py +++ b/src/Mod/Arch/importWebGL.py @@ -123,7 +123,7 @@ def export(exportList,filename): "exports the given objects to an .html file" html = getHTML(exportList) - outfile = pythonopen(filename,"wb") + outfile = pythonopen(filename,"w") outfile.write(html) outfile.close() FreeCAD.Console.PrintMessage(translate("Arch","Successfully written", utf8_decode=True) + ' ' + filename + "\n")