Project

General

Profile

Bug #30996

Mismatches between hammer full-help and hammer <command> --help

Added by Oleh Fedorenko 12 months ago. Updated 5 months ago.

Status:
Closed
Priority:
Normal
Category:
Other commands
Target version:
-

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1872783

`hammer full-help` and `hammer <command> --help` give different options in handful of cases. Usually `full-help` contains some option that is missing in `--help`.

This requires manual workaround on QE side, hence adding "AutomationBlocker" keyword.

Excerpt from `hammer full-help`:
#v+
hammer > content-view > add-version
-----------------------------------
Add a content view version to a composite view

Usage:
hammer content-view add-version [OPTIONS]

Options:
--content-view CONTENT_VIEW_NAME Content view name to search by
--content-view-id CONTENT_VIEW_ID Content view numeric identifier to search by
--content-view-version CONTENT_VIEW_VERSION_VERSION Content view version number
--content-view-version-id CONTENT_VIEW_VERSION_ID Content view version identifier
--id ID Content view numeric identifier
--name NAME Content view name to search by
--organization ORGANIZATION_NAME Organization name to search by
--organization-id ORGANIZATION_ID Organization ID to search by
--organization-label ORGANIZATION_LABEL Organization label to search by
h, --help Print help
#v

`hammer content-view add-version --help` for comparison:
#v+
Usage:
hammer content-view add-version [OPTIONS]

Options:
--content-view-id CONTENT_VIEW_ID Content view numeric identifier to search by
--content-view-version[-id] Set the current content view version context for the request. Version/Id can be used
--id ID Content view numeric identifier
--name NAME Content view name to search by
--organization ORGANIZATION_NAME Organization name to search by
--organization-id ORGANIZATION_ID Organization ID to search by
--organization-label ORGANIZATION_LABEL Organization label to search by
h, --help Print help
#v

As you can see, `full-help` mentions option `--content-view`, which is not present in `--help` output.

Full list of differences:
Present in `full-help` only:
hammer content-view add-version
option --content-view
hammer content-view remove
option --content-view-versions
option --lifecycle-environments
hammer discovery provision
option --partition-table
hammer file info
option --repository
option --content-view-version
hammer module-stream info
option --repository
hammer organization create
option --organization-label
hammer organization delete
option --organization-label
hammer organization info
option --organization-label
hammer organization list
option --organization-label
hammer organization update
option --organization-label
hammer user-group update
option --id

Present in `--help` only:
hammer user-group update
option user-group--id

Side note:
`hammer user-group update --help` reports `--user-group[s|--id]`, which looks like `--user-groups` and `--id` grouped in single command. However, that would make the only instance in entire Satellite where string inside square bracket is NOT appended to part before square bracket.

Found on:
Satellite 6.8 snap 12
katello-3.16.0-0.4.rc4.el7sat.noarch
satellite-6.8.0-1.el7sat.noarch
pulp-server-2.21.2-1.el7sat.noarch
foreman-2.1.1-1.el7sat.noarch
tfm-rubygem-hammer_cli-2.1.1-1.el7sat.noarch
tfm-rubygem-hammer_cli_katello-0.22.2-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman-2.1.2-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_remote_execution-0.1.2-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_discovery-1.0.2-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_tasks-0.0.14-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_admin-0.0.9-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_ansible-0.3.2-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_bootdisk-0.3.0-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_virt_who_configure-0.0.6-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_templates-0.2.0-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_azure_rm-0.2.0-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_docker-0.0.6.4-1.el7sat.noarch
tfm-rubygem-hammer_cli_foreman_openscap-0.1.10-1.el7sat.noarch


Related issues

Related to Discovery - Refactor #31691: Some options are built via legacy modeClosed
Related to Katello - Bug #31741: API docs contain misleading descriptionsClosed

Associated revisions

Revision bfe48a30 (diff)
Added by Oleh Fedorenko 5 months ago

Refs #30996 - Apply option family on SearchablesOptionBuilder

Revision ee8ce26a (diff)
Added by Oleh Fedorenko 5 months ago

Fixes #30996 - Better family assignment for options

Revision a13b068e
Added by Yifat Makias 5 months ago

Merge pull request #559 from ofedoren/bug-30996-better-family-search

Refs #30996 - Apply option family on SearchablesOptionBuilder

Revision 976edc80
Added by yifat makias 5 months ago

Merge pull request #339 from ofedoren/bug-30996-better-family-search

Fixes #30996 - Better family assignment for options

History

#1 Updated by Oleh Fedorenko 11 months ago

  • Assignee set to Oleh Fedorenko
  • Status changed from New to Assigned

#2 Updated by The Foreman Bot 8 months ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/hammer-cli/pull/339 added

#3 Updated by Oleh Fedorenko 8 months ago

#4 Updated by The Foreman Bot 8 months ago

  • Pull request https://github.com/theforeman/hammer-cli-foreman/pull/559 added

#5 Updated by Oleh Fedorenko 8 months ago

  • Related to Bug #31741: API docs contain misleading descriptions added

#6 Updated by The Foreman Bot 5 months ago

  • Fixed in Releases hammer-cli-2.4.0 added

#7 Updated by Oleh Fedorenko 5 months ago

  • Status changed from Ready For Testing to Closed

#8 Updated by Oleh Fedorenko 5 months ago

  • Fixed in Releases hammer-cli-2.3.1 added

#9 Updated by Oleh Fedorenko 5 months ago

  • Fixed in Releases hammer-cli-foreman-2.3.2, hammer-cli-foreman-2.5.0 added
  • Fixed in Releases deleted (hammer-cli-2.4.0)

Also available in: Atom PDF