def get_parent(fullpath):
    """
    Parse the string and return a path corresponding to the parent.
    Assumes normalized fullpath string.
    """
    parent = "/".join(fullpath.split('/')[:-1])
    if parent == '':  # a top-level hack
        parent = '/'
    return parent