metadata_file = os.path.join(workspace, dist_info_dir, "METADATA")
with open(metadata_file, "r") as info:
for line in info:
mo = _version_re.match(line)if mo:
input_version = mo.group("version")
breakif not input_version:
raise Exception("Could not find `Version:` line in {}".format(metadata_file))
// Rewrite and move all files (including the RECORD file), recording which files need to be