Showing
1 changed file
with
1 additions
and
1 deletions
| ... | @@ -50,7 +50,7 @@ if __name__ == "__main__": | ... | @@ -50,7 +50,7 @@ if __name__ == "__main__": |
| 50 | if f.endswith("_family.txt"): | 50 | if f.endswith("_family.txt"): |
| 51 | print("Processing...{}/{}".format(options.inputPath, f)) | 51 | print("Processing...{}/{}".format(options.inputPath, f)) |
| 52 | softText = '' | 52 | softText = '' |
| 53 | - with open(os.path.join(options.inputPath, f), "r", encoding="utf-8") as iFile: | 53 | + with open(os.path.join(options.inputPath, f), "r", encoding="utf-8", errors="replace") as iFile: |
| 54 | with open(os.path.join(options.outputPath, f.replace(".txt", ".xml")), "w", | 54 | with open(os.path.join(options.outputPath, f.replace(".txt", ".xml")), "w", |
| 55 | encoding="utf-8") as oFile: | 55 | encoding="utf-8") as oFile: |
| 56 | oFile.write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n\n<gse xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\nxsi:noNamespaceSchemaLocation=\"esquema-gcs.xsd\">\n\n") | 56 | oFile.write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n\n<gse xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\nxsi:noNamespaceSchemaLocation=\"esquema-gcs.xsd\">\n\n") | ... | ... |
-
Please register or login to post a comment