CLI is inconsistent in ordering columns

Bug #1659427 reported by Jim Baker
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Craton's Python Client
Fix Released
High
Ian Cordasco

Bug Description

$ craton host-list -r 1
+---------+----+-------------+-------------------------------------+--------+
| cell_id | id | device_type | name | active |
+---------+----+-------------+-------------------------------------+--------+
| 1 | 2 | server | host0.ORD135.C0001.C-1.example1.com | True |
| 1 | 3 | server | host1.ORD135.C0001.C-1.example1.com | True |
| 1 | 4 | server | host0.ORD135.C0001.C-2.example2.com | True |
| 1 | 5 | server | host1.ORD135.C0001.C-2.example2.com | True |
| 2 | 7 | server | host0.ORD135.C0002.C-1.example1.com | True |
| 2 | 8 | server | host1.ORD135.C0002.C-1.example1.com | True |
| 2 | 9 | server | host0.ORD135.C0002.C-2.example2.com | True |
| 2 | 10 | server | host1.ORD135.C0002.C-2.example2.com | True |
+---------+----+-------------+-------------------------------------+--------+
$ craton host-list -r 2
+---------+----------------------------------+----+-------------+--------+
| cell_id | name | id | device_type | active |
+---------+----------------------------------+----+-------------+--------+
| 3 | host0.DFW.C0001.C-1.example1.com | 12 | server | True |
| 3 | host0.DFW.C0001.C-2.example2.com | 14 | server | True |
| 3 | host1.DFW.C0001.C-1.example1.com | 13 | server | True |
| 3 | host1.DFW.C0001.C-2.example2.com | 15 | server | True |
| 4 | host1.DFW.C0002.C-2.example2.com | 20 | server | True |
+---------+----------------------------------+----+-------------+--------+

affects: craton → python-cratonclient
git-harry (git-harry)
Changed in python-cratonclient:
assignee: nobody → Ian Cordasco (icordasc)
git-harry (git-harry)
Changed in python-cratonclient:
importance: Undecided → High
Changed in python-cratonclient:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-cratonclient (master)

Reviewed: https://review.openstack.org/440810
Committed: https://git.openstack.org/cgit/openstack/python-cratonclient/commit/?id=683f3425069eed5aa792fad2368873d0e5140da8
Submitter: Jenkins
Branch: master

commit 683f3425069eed5aa792fad2368873d0e5140da8
Author: Ian Cordasco <email address hidden>
Date: Thu Mar 2 15:01:09 2017 -0600

    Make column ordering consistent and predictable

    This changes how we sort columns in listings and how we display the
    column headings. The default columns are now stored as lists so that
    they are the same from run to run. This simplifies some of the logic in
    the shell modules as well. Instead of keeping static mappings of
    attributes to column headings, we now use some simple python logic, to
    title case the columns.

    This commit covers:

    - cell-* commands
    - cloud-* commands
    - host-* commands
    - project-* commands
    - region-* commands

    Finally, we noticed that the cloud-list and region-list commands were
    behaving differently from the rest of the -list commands. This
    unifies the interface to add the --detail flag.

    Closes-bug: #1659103
    Closes-bug: #1659427
    Closes-bug: #1668221
    Change-Id: If5906780e501c7b9ba93ecf54a7bcf6db5ddfa1c

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

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

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

Reviewed: https://review.openstack.org/441261
Committed: https://git.openstack.org/cgit/openstack/python-cratonclient/commit/?id=99fd7c88a3e842ea31e8d3ec7cf54dd3ea8ccd7d
Submitter: Jenkins
Branch: master

commit 99fd7c88a3e842ea31e8d3ec7cf54dd3ea8ccd7d
Author: Ian Cordasco <email address hidden>
Date: Fri Mar 3 11:57:08 2017 -0600

    Make column ordering of devices-* consistent

    I missed this module in If5906780e501c7b9ba93ecf54a7bcf6db5ddfa1c

    Closes-bug: #1659103
    Closes-bug: #1659427
    Closes-bug: #1668221
    Change-Id: I4c3e3503568d426c116bdde48e2b11848f0d6aef

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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