summaryrefslogtreecommitdiff
path: root/openstackclient/volume/v2/volume_transfer_request.py
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2019-06-22 07:17:27 +0000
committerGerrit Code Review <review@openstack.org>2019-06-22 07:17:28 +0000
commitc20421c467872e407612e8bce85a76ef1cf9e025 (patch)
treef0ca0920719245e5b5837e3e21787750c4ddb4d1 /openstackclient/volume/v2/volume_transfer_request.py
parent0bc70a344f96624afddc1ca028bd8f11aa3a657d (diff)
parente76e10c0bac9cf87c564a7f0201df189f7cd8b52 (diff)
downloadpython-openstackclient-c20421c467872e407612e8bce85a76ef1cf9e025.tar.gz
Merge "Remove deprecated volume commands and args"
Diffstat (limited to 'openstackclient/volume/v2/volume_transfer_request.py')
-rw-r--r--openstackclient/volume/v2/volume_transfer_request.py23
1 files changed, 1 insertions, 22 deletions
diff --git a/openstackclient/volume/v2/volume_transfer_request.py b/openstackclient/volume/v2/volume_transfer_request.py
index 2f531dc8..4c4741bc 100644
--- a/openstackclient/volume/v2/volume_transfer_request.py
+++ b/openstackclient/volume/v2/volume_transfer_request.py
@@ -14,7 +14,6 @@
"""Volume v2 transfer action implementations"""
-import argparse
import logging
from osc_lib.command import command
@@ -39,14 +38,9 @@ class AcceptTransferRequest(command.ShowOne):
help=_('Volume transfer request to accept (ID only)'),
)
parser.add_argument(
- 'old_auth_key',
- metavar="<key>",
- nargs="?",
- help=argparse.SUPPRESS,
- )
- parser.add_argument(
'--auth-key',
metavar="<key>",
+ required=True,
help=_('Volume transfer request authentication key'),
)
return parser
@@ -64,21 +58,6 @@ class AcceptTransferRequest(command.ShowOne):
# move on and attempt with the user-supplied information
transfer_request_id = parsed_args.transfer_request
- # Remain backward-compatible for the previous command layout
- # TODO(dtroyer): Remove this back-compat in 4.0 or Oct 2017
- if not parsed_args.auth_key:
- if parsed_args.old_auth_key:
- # Move the old one into the correct place
- parsed_args.auth_key = parsed_args.old_auth_key
- self.log.warning(_(
- 'Specifying the auth-key as a positional argument '
- 'has been deprecated. Please use the --auth-key '
- 'option in the future.'
- ))
- else:
- msg = _("argument --auth-key is required")
- raise exceptions.CommandError(msg)
-
transfer_accept = volume_client.transfers.accept(
transfer_request_id,
parsed_args.auth_key,