credential set does not work as documented

Bug #1418837 reported by apal
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-openstackclient
Fix Released
Low
Sean Perry

Bug Description

(openstack) credential set -h
usage: credential set [-h] [--user <user>] [--type <type>] [--data <data>]
[--project <project>]
<credential-id>
Set credential command
positional arguments:
<credential-id> ID of credential to change
optional arguments:
-h, --help show this help message and exit
--user <user> Name or ID of user that owns the credential
--type <type> New credential type
--data <data> New credential data
--project <project> Project name or ID which limits the scope of the
credential
(openstack) credential set 50002651b7c5887a081b74b80fa0586a493857008c611c1b1e3a25c09d34e0cd --project admin
ERROR: openstack update() takes at least 3 arguments (3 given)
(openstack) credential set 50002651b7c5887a081b74b80fa0586a493857008c611c1b1e3a25c09d34e0cd --type ec2 --user apal-test --project apal-test
ERROR: openstack Credential requires blob to be specified
(openstack) credential set 50002651b7c5887a081b74b80fa0586a493857008c611c1b1e3a25c09d34e0cd --type ec2 --user apal-test --project apal-test --data "
{\"access\": \"testbfec279f1e904166a864bb0a4c4432ac\", \"secret\": \"7fd9c120d7f44bc7a491b08cf7792fedtset\"}
"
(openstack) (test_venv)cetest@cer106n0035:~$

Revision history for this message
Rodrigo Duarte (rodrigodsousa) wrote :

Hi, this seems as an openstackclient bug, will change the target.

affects: keystone → python-openstackclient
Dean Troyer (dtroyer)
Changed in python-openstackclient:
status: New → Confirmed
importance: Undecided → Low
Revision history for this message
Steve Martinelli (stevemar) wrote :

as a work around, use the ec2-credentials command by switching OS_IDENTITY_API_VERSION to 2.0

Changed in python-openstackclient:
milestone: none → m8
Ramaraja (ramaraja-r)
Changed in python-openstackclient:
assignee: nobody → Ramaraja (ramaraja-r)
Dean Troyer (dtroyer)
Changed in python-openstackclient:
milestone: m8 → m9
summary: - [Document Bug] credential set not work as help document (optional
- parameters actually required) - openstackcli
+ credential set does not work as documented
Ramaraja (ramaraja-r)
Changed in python-openstackclient:
status: Confirmed → In Progress
Revision history for this message
Ramaraja (ramaraja-r) wrote :

Can I get some guidance to reproduce this issue?. I have changed OS_IDENTITY_API_VERSION=3 and I able to List the set of credentials. when I am trying to set the credential, I am getting following error.

ERROR: openstack You are not authorized to perform the requested action: identity:list_projects (Disable debug mode to suppress these details.) (HTTP 403)

Dean Troyer (dtroyer)
Changed in python-openstackclient:
milestone: m9 → m10
Dean Troyer (dtroyer)
Changed in python-openstackclient:
milestone: m10 → none
Ramaraja (ramaraja-r)
Changed in python-openstackclient:
assignee: Ramaraja (ramaraja-r) → nobody
Changed in python-openstackclient:
assignee: nobody → Sean Perry (sean-perry-a)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-openstackclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/226922

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-openstackclient (master)

Reviewed: https://review.openstack.org/226922
Committed: https://git.openstack.org/cgit/openstack/python-openstackclient/commit/?id=b33cdec92ab3707886c12f49e9db27981114b35d
Submitter: Jenkins
Branch: master

commit b33cdec92ab3707886c12f49e9db27981114b35d
Author: Sean Perry <email address hidden>
Date: Wed Sep 23 10:39:13 2015 -0700

    Mark arguments for 'credential' commands as required

    According to the [1], 'user_id', 'type', and 'blob' are all required
    arguments for 'credential set' but the code treats them as optional. Set the
    'required' flag and remove logic supporting missing arguments.

    [1]: https://github.com/openstack/keystone-specs/blob/master/api/v3/identity-api-v3.rst#credentials-v3credentials "spec"

    Change-Id: I597c9616ad744385fc6dd92379feb03daec54458
    Closes-Bug: #1418837

Changed in python-openstackclient:
status: In Progress → Fix Committed
Changed in python-openstackclient:
milestone: none → 1.9.0
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.