(function from pyomo.common.modeling)
pyomo.common.modeling
Our implementation of random.randint.
The Python random.randint is not consistent between python versions and produces a series that is different in 3.x than 2.x. So that we can support deterministic testing (i.e., setting the random.seed and expecting the same sequence), we will implement a simple, but stable version of randint().