Bug 1346363 - hammer doesnt work with a "config" file in pwd
Summary: hammer doesnt work with a "config" file in pwd
Keywords:
Status: CLOSED DUPLICATE of bug 1255086
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Hammer
Version: 6.1.8
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Katello QA List
URL: http://projects.theforeman.org/issues...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-06-14 15:46 UTC by Sean O'Keeffe
Modified: 2016-06-16 11:46 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-06-16 11:46:04 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 15425 0 'Normal' 'Duplicate' 'hammer doesnt work with a "config" file in pwd' 2019-12-04 17:24:40 UTC

Description Sean O'Keeffe 2016-06-14 15:46:42 UTC
Description of problem:
Running hammer with a file called "config" and uncommented lines in cause hammer to fail.

Version-Release number of selected component (if applicable):
rubygem-hammer_cli-0.1.4.13-1.el7sat.noarch

How reproducible:
100%

Steps to Reproduce:
1. hammer --help (confirm it works fine)
2.cat /etc/sysconfig/selinux > config (this can be any file with uncommented text in)
3.hammer --help


Actual results:
[root@sat6 ~]# hammer --help
/usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:83:in `symbolize_hash': undefined method `inject' for "SELINUX=enforcing":String (NoMethodError)
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:71:in `deep_merge!'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:47:in `load'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:40:in `load_from_file'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:19:in `block in load_from_paths'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:16:in `each'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/lib/hammer_cli/settings.rb:16:in `load_from_paths'
	from /usr/share/gems/gems/hammer_cli-0.1.4.13/bin/hammer:52:in `<top (required)>'
	from /usr/bin/hammer:23:in `load'
	from /usr/bin/hammer:23:in `<main>'

Expected results:
hammer --help to display help message

Additional info:

Comment 1 Bryan Kearney 2016-06-15 17:24:02 UTC
Created redmine issue http://projects.theforeman.org/issues/15425 from this bug

Comment 3 Bryan Kearney 2016-06-16 11:46:04 UTC

*** This bug has been marked as a duplicate of bug 1255086 ***


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