-
Notifications
You must be signed in to change notification settings - Fork 180
faq 297566213
by John O on 2018-06-29 09:40:14
When running Matsim on Windows, the plans file written contains lines with both Unix (Lf) and Windows (CrLf) line endings because the attributes are written out in a different way (the correct one) from the rest of the information. This is true in 0.9.0 and seems to be the case in the current snapshot too.
org.matsim.utils.objectattributes.attributable.AttributesXmlWriterDelegate.writeAttributes()
uses: writer.newLine()
which writes the newline for the given operating system,
while
methods in org.matsim.core.population.io.PopulationWriterHandlerImplV6
use: out.write("\n");
which outputs just an Lf, regardless of the operating system.
This is fine for Unix-like systems but on Windows, the file has mixed endings.
by Kai Nagel on 2018-08-05 13:19:11
Thanks for the note. I put it into https://matsim.atlassian.net/browse/MATSIM-843 . Might take some time to fix this since "\n" for line endings is a normal convention for many of us. But I agree that this is not good, and even worse when it is in the same file.
You are viewing an archive of the previous MATSim Q&A site. The real site is now at https://matsim.org/faq