Help message for port-create command does not fully reflect supported subnet_id variant of --fixed-ip option

Bug #1267465 reported by Ihar Hrachyshka
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-neutronclient
Fix Released
Undecided
Ihar Hrachyshka

Bug Description

1. It does not mention subnet_id variant at all.

[root@rhel65 tempest(keystone_admin)]# neutron port-create
usage: neutron port-create [-h] [-f {shell,table}] [-c COLUMN]
                           [--variable VARIABLE] [--prefix PREFIX]
                           [--request-format {json,xml}]
                           [--tenant-id TENANT_ID] [--name NAME]
                           [--admin-state-down] [--mac-address MAC_ADDRESS]
                           [--device-id DEVICE_ID]
                           [--fixed-ip ip_address=IP_ADDR]
                           [--security-group SECURITY_GROUP | --no-security-groups [--extra-dhcp-opt EXTRA_DHCP_OPTS]
                           NETWORK
neutron port-create: error: too few arguments

2. When using --help, it mentions it inconsistently.

...
  --fixed-ip ip_address=IP_ADDR
                        Desired IP for this port:
                        subnet_id=<name_or_id>,ip_address=<ip>, (This option
                        can be repeated.)
...

This should make it clear you can use subnet_id argument without ip_address, to rely on Neutron to select one of IP addresses from the requested subnet.

Changed in python-neutronclient:
assignee: nobody → Ihar Hrachyshka (ihar-hrachyshka)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-neutronclient (master)

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

Changed in python-neutronclient:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-neutronclient (master)

Reviewed: https://review.openstack.org/65690
Committed: https://git.openstack.org/cgit/openstack/python-neutronclient/commit/?id=15f9a0f469ecb3ac8e6a2fe744608951c629b3d2
Submitter: Jenkins
Branch: master

commit 15f9a0f469ecb3ac8e6a2fe744608951c629b3d2
Author: Ihar Hrachyshka <email address hidden>
Date: Thu Jan 9 14:24:28 2014 +0100

    Mention --fixed-ip subnet_id=<..> in help message

    Improved help message for port-create --fixed-ip subnet_id=<..> case:
     * ensure it's mentioned when no arguments are passed;
     * fixed wording of --help message to make it clear subnet_id may be
       passed without ip_address.

    Change-Id: Ie48099e0445f80dbff78766e42bc548f925cd208
    Closes-Bug: #1267465

Changed in python-neutronclient:
status: In Progress → Fix Committed
Akihiro Motoki (amotoki)
Changed in python-neutronclient:
milestone: none → 2.3.0-2.3.4
Akihiro Motoki (amotoki)
Changed in python-neutronclient:
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.