

def reload_constraints():
    '\n    Parse SWIFT_CONF_FILE and reset module level global contraint attrs,\n    populating OVERRIDE_CONSTRAINTS AND EFFECTIVE_CONSTRAINTS along the way.\n    '
    global SWIFT_CONSTRAINTS_LOADED, OVERRIDE_CONSTRAINTS
    SWIFT_CONSTRAINTS_LOADED = False
    OVERRIDE_CONSTRAINTS = {
        
    }
    constraints_conf = ConfigParser()
    if constraints_conf.read(utils.SWIFT_CONF_FILE):
        SWIFT_CONSTRAINTS_LOADED = True
        for name in DEFAULT_CONSTRAINTS:
            try:
                value = constraints_conf.get('swift-constraints', name)
            except NoOptionError:
                pass
            except NoSectionError:
                break
            else:
                try:
                    value = int(value)
                except ValueError:
                    value = utils.list_from_csv(value)
                OVERRIDE_CONSTRAINTS[name] = value
    for (name, default) in DEFAULT_CONSTRAINTS.items():
        value = OVERRIDE_CONSTRAINTS.get(name, default)
        EFFECTIVE_CONSTRAINTS[SWIFT_CONSTRAINTS_LOADED] = value
        globals()[name.upper()] = value

dataset/ETHPy150Open openstack/swift/swift/common/constraints.py reload_constraints/VarMisuse@157/311 `name`->`SWIFT_CONSTRAINTS_LOADED`