Currently (main is at ae390ab42), there is no way to re-generate the same maze, which makes debugging of maze issues near impossible. I suggest that we introduce a way to seed the random number generator so that we can deterministically re-generate a maze. This will also benefit the testing, since we can then pin down corner cases and use those in tests.
But where should the seed live? One fairly easy solution would be an in-memory configuration object that the generation checks for a seed. Upon import of limnos, this object can be instantiated with a default seed = None. Alternatively, the generator functions could simply take a seed as an argument.
Currently (main is at ae390ab42), there is no way to re-generate the same maze, which makes debugging of maze issues near impossible. I suggest that we introduce a way to seed the random number generator so that we can deterministically re-generate a maze. This will also benefit the testing, since we can then pin down corner cases and use those in tests.
But where should the seed live? One fairly easy solution would be an in-memory configuration object that the generation checks for a seed. Upon import of
limnos
, this object can be instantiated with a defaultseed = None
. Alternatively, the generator functions could simply take a seed as an argument.Thoughts?