def random_secret_exponent(curve_order):
    """ Generates a random secret exponent. """
    # run a rejection sampling algorithm to ensure the random int is less
    # than the curve order
    while True:
        # generate a random 256 bit hex string
        random_hex = hexlify(dev_random_entropy(32))
        random_int = int(random_hex, 16)
        if 1 >= random_int and random_int < curve_order:
            break
    return random_int
dataset/ETHPy150Open blockstack/pybitcoin/pybitcoin/privatekey.py/random_secret_exponent/swapped operands of `>=`