Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File_line[disable-tools-version]: Could not evaluate: can't convert Hash into String #61

Open
akomakom opened this issue Apr 7, 2017 · 1 comment

Comments

@akomakom
Copy link

akomakom commented Apr 7, 2017

I recently upgraded my stdlib module to puppetlabs-stdlib (v4.16.0) from (v4.6.0). As a consequence, vmwaretools no longer works. I reverted back to 4.6.0 and there is no error.

My guess is that Package[$package_real] seems to be the issue, since that's the only relevant Hash. Note that in the output, Puppet may be choosing not to add the Package to the catalog.

  • CentOS 6
  • Puppet 3.8.7
  • puppetlabs-stdlib (v4.16.0)
  • razorsedge-vmwaretools (v6.0.0)

Usage:

class{ "vmwaretools": ensure => 'absent' }

Error:

Debug: Executing '/bin/rpm -q vmware-tools-esx-nox --nosignature --nodigest --qf %{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} %{RELEASE} %{ARCH}\n'
Debug: /Stage[main]/Vmwaretools/Package[vmware-tools-esx-nox]: Nothing to manage: no ensure and the resource doesn't exist
Debug: Executing '/bin/rpm -q vmware-tools-esx-kmods --nosignature --nodigest --qf %{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} %{RELEASE} %{ARCH}\n'
Debug: /Stage[main]/Vmwaretools/Package[vmware-tools-esx-kmods]: Nothing to manage: no ensure and the resource doesn't exist
Error: /Stage[main]/Vmwaretools/File_line[disable-tools-version]: Could not evaluate: can't convert Hash into String
Notice: /Stage[main]/Vmwaretools/Service[vmware-tools-services]: Dependency File_line[disable-tools-version] has failures: true
Warning: /Stage[main]/Vmwaretools/Service[vmware-tools-services]: Skipping because of failed dependencies
Debug: Class[Vmwaretools]: The container Stage[main] will propagate my refresh event

I attempted to verify that ensure is set to a value for the Package[$package_real] resource by adding this to init.pp:

notify{"Package ensure is ${package_ensure}":}

And the printout confirms that the value is "absent" and not undef.

@razorsedge razorsedge self-assigned this Jun 26, 2017
@razorsedge
Copy link
Contributor

@akomakom Are you running under ruby 1.8.7? If so, have you tried using puppetlabs-stdlib 4.17.0?

@razorsedge razorsedge removed their assignment Apr 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants