vmware-archive / vcd-cli

Command Line Interface for VMware vCloud Director
https://vmware.github.io/vcd-cli
Other
165 stars 106 forks source link

Wrong format of task statuses. #494

Closed BoringDude closed 5 years ago

BoringDude commented 5 years ago

Hi all,

Have an issue with "task list" and "task update" operations (tested for API v.31 and v.29):

vcd task list RUNNING   
Error: Status code: 400/BAD_REQUEST, Value 'RUNNING' not found. (request id: 6837087d-ece5-4a7e-8328-d7c48a3a782b)
vcd task update ABORTED cfb48619-8754-4b16-b5e2-7e8e7c382d81   
Error: Status code: 400/BAD_REQUEST, Value 'ABORTED' not found. (request id: af9164e3-406d-49cc-b3f3-69b437cea627)

at the same time there's no way to use the parameters in the lower case

vcd task list running
Error: Invalid value for "[QUEUED|PRE_RUNNING|RUNNING|SUCCESS|ERROR|CANCELED|ABORTED]": invalid choice: running. (choose from QUEUED, PRE_RUNNING, RUNNING, SUCCESS, ERROR, CANCELED, ABORTED)

The error appears for all statuses.

After digging API docs, it seems like the root cause is the "status" parameter must be in the lower case but it sends in the upper case.

pandeys commented 5 years ago

It is a bug. We will take it in our backlog.