better random management
Merge branch 'sudorandom' into test