object list --delimiter returns empty strings

Bug #1737530 reported by Leopold Talirz
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-openstackclient
New
Undecided
Unassigned

Bug Description

I'm trying to use the `--delimiter /` option to get a list of subdirectories in a container.
Using python-swiftclient it works:

$ swift list backup-dev-tools --delimiter /
abc/
logs/

With the python-openstackclient, however, I get

$ openstack object list backup-dev-tools --delimiter /
+------+
| Name |
+------+
| |
| |
+------+

I believe the reason is that the format of the RESP BODY dictionary changes when you specify the --delimiter option.

With --delimiter:
RESP BODY: [{"subdir": "abc/"}, {"subdir": "logs/"}]
Without --delimiter:
RESP BODY: [{"hash": "d41d8cd98f00b204e9800998ecf8427e", "last_modified": "2017-12-11T11:45:43.340020", "bytes": 0, "name": "abc/", "content_type": "application/octet-stream"}, ...]

I.e. it should show be using the 'subdir' key instead of the 'name' key, when specifying --delimiter.

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.