@Commands.command(
        'edit',
        aliases=('e',),
        help=[
            'Edit an existing bundle\'s metadata.',
            '  edit           : Popup an editor.',
            '  edit -n <name> : Edit the name metadata field (same for other fields).',
        ],
        arguments=(
            Commands.Argument('bundle_spec', help=BUNDLE_SPEC_FORMAT, completer=BundlesCompleter),
            Commands.Argument('-n', '--name', help='Change the bundle name (format: %s).' % spec_util.NAME_REGEX.pattern),
            Commands.Argument('-d', '--description', help='New bundle description.'),
            Commands.Argument('-w', '--worksheet-spec', help='Operate on this worksheet (%s).' % WORKSHEET_SPEC_FORMAT, completer=WorksheetsCompleter),
        ),
    )
    def do_edit_command(self, args):
        client, worksheet_uuid = self.parse_client_worksheet_uuid(args.worksheet_spec)
        bundle_uuid = worksheet_util.get_bundle_uuid(client, worksheet_uuid, args.bundle_spec)
        info = client.get_bundle_info(bundle_uuid)
        bundle_subclass = get_bundle_subclass(info['bundle_type'])

        metadata = info['metadata']
        new_metadata = copy.deepcopy(metadata)
        is_new_metadata_updated = False
        if args.name:
            new_metadata['name'] = args.name
            is_new_metadata_updated = True
        if args.description:
            new_metadata['description'] = args.description
            is_new_metadata_updated = True

        # Prompt user for all information
        if not is_new_metadata_updated and not self.headless and metadata == new_metadata:
            new_metadata = self.get_missing_metadata(bundle_subclass, args, new_metadata)

        if metadata != new_metadata:
            client.update_bundle_metadata(bundle_uuid, new_metadata)
            print >>self.stdout, (bundle_uuid) % "Saved metadata for bundle %s."
dataset/ETHPy150Open codalab/codalab-cli/codalab/lib/bundle_cli.py/BundleCLI.do_edit_command/swapped operands of `%`