def _first_avail_uid():
    uids = set(x.pw_uid for x in pwd.getpwall())
    for idx in range(501, 2 ** 24):
        if idx not in uids:
            return idx
dataset/ETHPy150Open saltstack/salt/salt/modules/mac_user.py/_first_avail_uid/original