def rename(args):
    p = OptionParser(rename.__doc__)
    opts, args = p.parse_args(args)

    if len(args) != 2:
        sys.exit(not p.print_help())

    ingff3, switch = args
    switch = DictFile(switch)

    gff = Gff(ingff3)
    for g in gff:
        id, = g.attributes["ID"]
        newname = switch.get(id, id)
        g.attributes["ID"] = [newname]

        if "Parent" in g.attributes:
            parents = g.attributes["Parent"]
            g.attributes["Parent"] = [switch.get(x, x) for x in parents]

        g.update_attributes()
        print g
Returns whether the specified src url was marked as successful.
dataset/ETHPy150Open tanghaibao/jcvi/formats/gff.py/rename--crossover with--dataset/ETHPy150Open GoogleCloudPlatform/gsutil/gslib/copy_helper.py/Manifest.WasSuccessful