allow JSON to encode UTF-8

This commit is contained in:
James Powell
2018-10-29 11:17:13 -04:00
parent bcf93e1d9f
commit 4f4f05abdf
8 changed files with 9 additions and 11 deletions

View File

@@ -159,7 +159,7 @@ if __name__ == '__main__':
for p in test:
result.append(Result_element(pths[test.index(p)],p))
with open(args.output, 'w') as f:
f.write(dumps(path_result_json(result), indent=2))
f.write(dumps(path_result_json(result), indent=2, ensure_ascii=False))
fnamecsv = next(s for s in args.output.split('.')) + '.csv'
with open(fnamecsv,"w") as fcsv :
jsontocsv(path_result_json(result),equipment,fcsv)