saharaclient should check the input param when cluster-create

Bug #1419643 reported by warewang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Python client library for Sahara
Won't Fix
Low
warewang

Bug Description

I excute the shell command--sahara cluster-create, I wait a long time, but it return nothing. I look at the cold, found that :
@utils.arg('--json',
           default=sys.stdin,
           type=argparse.FileType('r'),
           help='JSON representation of cluster.')
def do_cluster_create(cs, args):
    """Create a cluster."""
    # TODO(mattf): improve template validation, e.g. template w/o name key
    template = json.loads(args.json.read())
    # The neutron_management_network parameter to clusters.create is
    # called net_id. Therefore, we must translate before invoking
    # create w/ **template. It may be desirable to simple change
    # clusters.create in the future.
    remap = {'neutron_management_network': 'net_id'}
    _filter_call_args(template, cs.clusters.create, remap)

    _show_cluster(cs.clusters.create(**template))

I think, if args is none, the default is stdin, so the thread is wait the user's input. I think it need to judge the args shoud not be empty.

warewang (wangguangcai)
Changed in sahara:
assignee: nobody → warewang (wangguangcai)
Revision history for this message
Andrew Lazarev (alazarev) wrote :

As I remember it was done intentionally. I'm not sure what the right behavior, a good topic to discuss on weekly meeting.

summary: - saharaclient should check the input parama whencluster-create
+ saharaclient should check the input param when cluster-create
Revision history for this message
Michael McCune (mimccune) wrote :

marking this as triaged since we have agreed that it requires further information from the dev team.

this has been added to the weekly meeting agenda for August 20.

Changed in sahara:
status: New → Triaged
Changed in sahara:
status: Triaged → Confirmed
affects: sahara → python-saharaclient
Elise Gafford (egafford)
Changed in python-saharaclient:
importance: Undecided → Low
Revision history for this message
Vitalii Gridnev (vgridnev) wrote :

The bug touches old CLI which is deprecated

Changed in python-saharaclient:
status: Confirmed → Won't Fix
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.