Hi,
I wanted to test out dsc_resource after WMF5.0 was finally re-released (via test kitchen). But it fails with error:
ArgumentError
wrong number of arguments (1 for 0)
This is on a Server 2012 R2 machine. PSVersion is 5.0.10586.117
Chef Workstation (win7) has the following:
Chef Development Kit Version: 0.11.2
chef-client version: 12.7.2
berks version: 4.2.0
kitchen version: 1.5.0
Resource:
dsc_resource ‘install-sub-features’ do
resource_name :windowsfeature
property :ensure, 'Present’
property :name, 'msmq’
property :IncludeAllSubFeature, true
end
Any ideas?
Thanks
stacktrace.out
Generated at 2016-03-24 15:03:26 +0000
ArgumentError: wrong number of arguments (1 for 0)
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/resource.rb:916:in resource_name' C:/Users/vagrant/AppData/Local/Temp/kitchen/cache/cookbooks/comp/recipes/wmf5.rb:31:in
block in from_file’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/resource_builder.rb:76:in instance_eval' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/resource_builder.rb:76:in
build’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/dsl/declare_resource.rb:104:in build_resource' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/dsl/declare_resource.rb:62:in
declare_resource’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/dsl/resources.rb:40:in dsc_resource' C:/Users/vagrant/AppData/Local/Temp/kitchen/cache/cookbooks/comp/recipes/wmf5.rb:30:in
from_file’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/mixin/from_file.rb:30:in instance_eval' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/mixin/from_file.rb:30:in
from_file’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/cookbook_version.rb:233:in load_recipe' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context.rb:332:in
load_recipe’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context/cookbook_compiler.rb:140:in block in compile_recipes' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context/cookbook_compiler.rb:138:in
each’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context/cookbook_compiler.rb:138:in compile_recipes' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context/cookbook_compiler.rb:75:in
compile’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/run_context.rb:167:in load' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/policy_builder/expand_node_object.rb:97:in
setup_run_context’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/client.rb:509:in setup_run_context' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/client.rb:277:in
run’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application.rb:252:in run_with_graceful_exit_option' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application.rb:228:in
block in run_chef_client’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/local_mode.rb:44:in with_server_connectivity' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application.rb:211:in
run_chef_client’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application/client.rb:445:in block in interval_run_chef_client' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application/client.rb:435:in
loop’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application/client.rb:435:in interval_run_chef_client' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application/client.rb:424:in
run_application’
C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/lib/chef/application.rb:58:in run' C:/opscode/chef/embedded/lib/ruby/gems/2.0.0/gems/chef-12.8.1-universal-mingw32/bin/chef-client:26:in
<top (required)>'
C:/opscode/chef/bin/chef-client:60:in load' C:/opscode/chef/bin/chef-client:60:in
’