INNER CODE UNIT · Python

yamlize_dict

aehrc/VariantSpark · cloud/aws-emr/python/vs_emr/cli.py:100

def yamlize_dict(d):
    def convert_value(v):
        if type(v) == dict:
            return yamlize_dict(v)
        elif type(v) == bool:
            return str(v).lower()
        elif v is None:
            return "null"
        else:
            return v
    return dict( (k,convert_value(v)) for k,v in d.items())
    
    

def dict_put(dictionary, pv ):
    path_key, value = pv
    dict_put_path(dictionary, path_key, value)
    return dictionary

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…