Mindwerks / worldengine

World generator using simulation of plates, rain shadow, erosion, etc.
MIT License
989 stars 129 forks source link

Investigate crashes due to usage of grayscale-heightmap and rivers options #113

Closed ftomassetti closed 9 years ago

ftomassetti commented 9 years ago

whenever I use the parameters --grayscale-heightmap="..." or --rivers="..." the program crashes with the following output (of course I didn't just put in "..."):

--Linux output: Producing ouput:

--Windows output: Producing ouput:

psi29a commented 9 years ago

This looks like fun... pay no attention to the paths, that isn't the problem.

@ftomassetti have you managed to reproduce this (binary and straight from source).

ftomassetti commented 9 years ago

nope, I did not tried yet

psi29a commented 9 years ago

Isn't a crash, but rather PILLOW (PIL) that only looks at the extension of the filename to determine what format to save the image (river or greyscale) to. So a bad extension 'crap' from "blah.crap" will throw a keyerror because crap doesn't exist.

I catch this error, and append a 'png' along with an message saying why.

I also try looking for '.' in the filename at the start and verify it exists, otherwise error out with message why.

ftomassetti commented 9 years ago

Thanks!