Bug 1053573 - Hammer : CLI `os info` fails after the adding parameter to os
Summary: Hammer : CLI `os info` fails after the adding parameter to os
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Provisioning
Version: Nightly
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: Unspecified
Assignee: Ohad Levy
QA Contact: Sachin Ghai
URL: http://projects.theforeman.org/issues...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-01-15 12:45 UTC by Tazim Kolhar
Modified: 2019-09-26 17:42 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-07-02 14:08:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
foreman-debug (107.71 KB, application/x-xz)
2014-01-15 12:45 UTC, Tazim Kolhar
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 4136 0 None None None 2016-04-22 16:40:55 UTC

Description Tazim Kolhar 2014-01-15 12:45:38 UTC
Created attachment 850477 [details]
foreman-debug

Description of problem:
`os info` fails after the adding parameter to os 

Version-Release number of selected component (if applicable):
# rpm -qa | grep foreman
rubygem-hammer_cli_foreman-0.0.15-1.el6.noarch
foreman-installer-1.4.0-0.develop.201401102003gitcc00eed.el6.noarch
foreman-selinux-1.4.0-0.develop.201311220906gite342a0b.el6.noarch
rubygem-foreman_api-0.1.9-1.el6.noarch
foreman-compute-1.4.0-0.develop.201401111533git229d743.el6.noarch
foreman-proxy-1.4.0-0.develop.201401031522gitd3509e6.el6.noarch
foreman-libvirt-1.4.0-0.develop.201401111533git229d743.el6.noarch
foreman-release-1.4.0-0.develop.201401111533git229d743.el6.noarch
foreman-1.4.0-0.develop.201401111533git229d743.el6.noarch
foreman-ovirt-1.4.0-0.develop.201401111533git229d743.el6.noarch
foreman-postgresql-1.4.0-0.develop.201401111533git229d743.el6.noarch


How reproducible:
everytime

Steps to Reproduce:
1.# hammer os set_parameter --os-id 6 --name testname --value testvalue
New operating system parameter created

2.# hammer os info --id 6
Id:                  6
Name:                testos 4.3
Release name:        
Family:              Debian
Installation media:  
Architectures:       
Partition tables:    
Config templates:    
Parameters:          
/usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/utils.rb:12:in `%': malformed format string - %{ (ArgumentError)
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/utils.rb:12:in `format'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/output/adapter/abstract.rb:27:in `print_error'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/output/output.rb:16:in `print_error'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/exception_handler.rb:42:in `print_error'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/exception_handler.rb:58:in `handle_general_exception'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/exception_handler.rb:25:in `send'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/exception_handler.rb:25:in `handle_exception'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/abstract.rb:177:in `handle_exception'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/lib/hammer_cli/abstract.rb:26:in `run'
	from /usr/lib/ruby/gems/1.8/gems/clamp-0.6.2/lib/clamp/command.rb:125:in `run'
	from /usr/lib/ruby/gems/1.8/gems/hammer_cli-0.0.14/bin/hammer:61
	from /usr/bin/hammer:19:in `load'
	from /usr/bin/hammer:19

3.

Actual results:
os info fails

Expected results:
os info should work

Additional info:

Comment 1 RHEL Program Management 2014-01-15 12:56:12 UTC
Since this issue was entered in Red Hat Bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

Comment 4 Martin Bacovsky 2014-02-04 09:29:51 UTC
This issue was fixed in hammer 0.0.18

Comment 6 Sachin Ghai 2014-05-06 09:15:27 UTC
Verified with Satellite-6.0.3-RHEL-6-20140430.4

os_info works


[root@qetello02 yum.repos.d]# hammer os set-parameter --name 'testparam' --value 'works' --os-id 68
New operating system parameter created


[root@qetello02 yum.repos.d]# hammer os info --id 68
Id:                   68
Name:                 testos 2
Release name:         
Family:               
Installation media:   
Architectures:        
Partition tables:     
Config templates:     
Default OS templates: 
Parameters:           
 1) testparam => works

Comment 7 Bryan Kearney 2014-07-02 14:08:27 UTC
This was delivered with 6.0.3, which is the Satellite 6 Beta.

Comment 8 Bryan Kearney 2014-07-02 14:09:45 UTC
This was delivered in 6.0.3, the Beta version of Satellite 6.0


Note You need to log in before you can comment on or make changes to this bug.