Bug #17216

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

Added by Ondřej Pražák 7 months ago. Updated 7 months ago.

Status:New
Priority:Normal
Assigned To:-
Category:Compute resources
Target version:Foreman - Team Marek backlog
Difficulty: Bugzilla link:1387653
Found in release: Pull request:
Story points-
Velocity based estimate-

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.

History

#1 Updated by Ondřej Pražák 7 months 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

#2 Updated by Tomáš Strachota 7 months ago

  • Target version set to Team Marek backlog

Also available in: Atom PDF