Project

General

Profile

Actions

Bug #17216

closed

"hammer compute-resource image available" requires specifying id or name twice

Added by Ondřej Pražák over 7 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Compute resources
Target version:
-
Difficulty:
Triaged:
No
Team Backlog:
Marek
Fixed in Releases:
Found in Releases:
In Kanboard:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1387653
Description of problem:

  1. hammer compute-resource image available -h
    Usage:
    hammer compute-resource image available [OPTIONS]
Options:
--compute-resource NAME
--compute-resource-id ID
--id ID
--name NAME Compute resource name
-h, --help print help
Apparently, the --compute-resource-id option is the same as --id, but hammer requires both:
  1. hammer compute-resource image available --compute-resource-id 7
    Missing arguments for 'id'
  2. hammer compute-resource image available --id 7
    Error: At least one of options --compute-resource-id, --compute-resource is required
  3. hammer compute-resource image available --compute-resource-id 7 --id 7
    -----|-----
    NAME | UUID
    -----|-----
The same goes for names:
  1. hammer compute-resource image available --compute-resource local_libvirt
    Missing arguments for 'id'
  2. hammer compute-resource image available --name local_libvirt
    Error: At least one of options --compute-resource-id, --compute-resource is required
  3. hammer compute-resource image available --compute-resource local_libvirt --name local_libvirt
    -----|-----
    NAME | UUID
    -----|-----
Expected results:
Redundant options should be removed, "hammer compute-resource image available" should require the cr id or name just once.
Actions #1

Updated by Ondřej Pražák over 7 years ago

  • Subject changed from "hammer compute-resource image available" requires specifying id or name twice to "hammer compute-resource image available" requires specifying id or name twice
  • Category set to Compute resources
Actions #2

Updated by Tomáš Strachota over 7 years ago

  • Target version set to 115
Actions #3

Updated by Shira Maximov over 4 years ago

  • Status changed from New to Closed
  • Triaged set to No

This issue was already fixed:

hammer compute-resource image available --help
Usage:
hammer compute-resource image available [OPTIONS]

Options:
--compute-resource NAME Compute resource name
--compute-resource-id ID
--fields FIELDS Show specified fileds or predefined filed sets only. (See below)
Comma separated list of values. Values containing comma should be quoted or escaped with backslash.
JSON is acceptable and preferred way for complex parameters
--location LOCATION_NAME Location name
--location-id LOCATION_ID
--location-title LOCATION_TITLE Location title
--organization ORGANIZATION_NAME Organization name
--organization-id ORGANIZATION_ID
--organization-title ORGANIZATION_TITLE Organization title
-h, --help Print help

hammer compute-resource image available --compute-resource-id 31
--------|-------------------------------------
NAME | UUID
--------|-------------------------------------
RHEL7_3 | 5035573e-59e9-8fe0-7892-482c75cda559
--------|-------------------------------------

Actions

Also available in: Atom PDF