Bug #22879
closedHammerCLIKatello::ContentViewPuppetModule::CreateCommand.get_identifier wrong numer of arguments
Description
HammerCLIKatello::ContentViewPuppetModule::CreateCommand.get_identifier overrides HammerCLIForeman::Command.get_identifier(all_opts=all_options)
https://github.com/theforeman/hammer-cli-foreman/commit/c61d1365f1bbb7ab8d3a54ed14eeb10a6100b0eb#diff-25c31437e73b23714ac3ea197aa60b15R118
so calling it
https://github.com/theforeman/hammer-cli-foreman/blob/master/lib/hammer_cli_foreman/option_sources/self_param.rb#L11
without arguments causes exception
how to reproduce:
- hammer -v -u admin -p changeme --output=csv content-view puppet-module add --content-view-id="509" --name="versioned" --author="robottelo"
Could not add the puppet module:
wrong number of arguments (given 1, expected 0)
ArgumentError (wrong number of arguments (given 1, expected 0)):
/opt/theforeman/tfm/root/usr/share/gems/gems/hammer_cli_katello-0.11.0/lib/hammer_cli_katello/content_view_puppet_module.rb:40:in `get_identifier'
/opt/theforeman/tfm/root/usr/share/gems/gems/hammer_cli_foreman-0.13.pre.develop/lib/hammer_cli_foreman/option_sources/self_param.rb:11:in `get_options'
/opt/theforeman/tfm/root/usr/share/gems/gems/hammer_cli-0.12.0/lib/hammer_cli/options/option_collector.rb:13:in `block in all_options_raw'
...
Updated by Ales Dujicek almost 7 years ago
- Pull request https://github.com/Katello/hammer-cli-katello/pull/548 added
related to http://projects.theforeman.org/issues/21768
Updated by Ales Dujicek almost 7 years ago
- Related to Bug #21768: Support NIL values in searchable options added
Updated by Ales Dujicek almost 7 years ago
- Status changed from New to Duplicate
Ah, yes it is, I did not find it
Updated by Ales Dujicek almost 7 years ago
- Is duplicate of Bug #22763: hammer content-view puppet-module add raises ArgumentError (wrong number of arguments (given 1, expected 0)) added