def get_snapshots_from_text(query_output):
    """ Translate expanded snapshots from `cali-query -e` output into list of dicts 

        Takes input in the form 

          attr1=x,attr2=y
          attr1=z
          ...

        and converts it to `[ { 'attr1' : 'x', 'attr2' : 'y' }, { 'attr1' : 'z' } ]`
    """

    snapshots = []

    for line in query_output.decode().splitlines():
        snapshots.append( { kv.partition('=')[0] : kv.partition('=')[2] for kv in line.split(',') } )

    return snapshots