I am parsing a CSV document to write a specification in SysML v2, which is essentially just a simple text file. Parsing it on Linux I get the result I desire. I use a SysOn-Docker to display my SysML v2 file and everything works as it's supposed to. However, when I parse create the file in Windows there are special characters appearing: NBSP SPA It seems, due to these characters the SysOn Docker can't properly read the file in the Windows Docker (however, under Linux no issues at all). I have tried several ways to write the file differently: with open(filename, "w") as text_file: text_file.write(systring) with codecs.open(filename, "w", "utf-8-sig") as text_file: text_file.write(systring) with io.open(filename, 'w', encoding="utf-8) as file: text_file.write(systring) However, all with the same result. The file doesn't change. Right now I'm really considering removing all of these special characters manually with a .replace - but it doesn't seem to be the proper way? Continue reading...