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

Test recipe fails to compile with Chef 13 warning #134

Closed
tas50 opened this issue Feb 19, 2017 · 0 comments · Fixed by #135
Closed

Test recipe fails to compile with Chef 13 warning #134

tas50 opened this issue Feb 19, 2017 · 0 comments · Fixed by #135

Comments

@tas50
Copy link
Contributor

tas50 commented Feb 19, 2017

Cookbook version

1.0.0

Chef-client version

12.18

Platform Details

Ubuntu 16.04

The following warning is thrown for Chef 13 that needs to be resolves prior to the release:

       Compiling Cookbooks...
       [2017-02-19T03:27:41+00:00] ERROR: An attempt was made to change version from :latest to nil by calling version(nil). In Chef 12, this does a get rather than a set. In Chef 13, this will change to set the value to nil. (CHEF-5)/tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:3:in `block in from_file'.
       Please see https://docs.chef.io/deprecations_custom_resource_cleanups.html for further details and information on how to correct this problem. at /opt/chef/embedded/lib/ruby/gems/2.3.0/gems/chef-12.18.31/lib/chef/formatters/doc.rb:419:in `deprecation'

       ================================================================================
       Recipe Compile Error in /tmp/kitchen/cache/cookbooks/test/recipes/repo.rb
       ================================================================================

       Chef::Exceptions::DeprecatedFeatureError
       ----------------------------------------
       "An attempt was made to change version from :latest to nil by calling version(nil). In Chef 12, this does a get rather than a set. In Chef 13, this will change to set the value to nil. (CHEF-5)/tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:3:in `block in from_file'.\nPlease see https://docs.chef.io/deprecations_custom_resource_cleanups.html for further details and information on how to correct this problem. at /opt/chef/embedded/lib/ruby/gems/2.3.0/gems/chef-12.18.31/lib/chef/formatters/doc.rb:419:in `deprecation'"

       Cookbook Trace:
       ---------------
         /tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:3:in `block in from_file'
         /tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:2:in `from_file'

       Relevant File Content:
       ----------------------
       /tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:

         1:  # Chef Server Core
         2:  chef_ingredient 'chef-server' do
         3>>   version node['test']['chef-server-core']['version']
         4:    config <<-EOS
         5:  api_fqdn "#{node['fqdn']}"
         6:  ip_version "ipv6"
         7:  notification_email "#{node['chef_admin']}"
         8:  nginx["ssl_protocols"] = "TLSv1 TLSv1.1 TLSv1.2"
         9:  EOS
        10:    action :install
        11:  end
        12:

       Platform:
       ---------
       x86_64-linux


       Running handlers:
       [2017-02-19T03:27:41+00:00] ERROR: Running exception handlers
       Running handlers complete
       [2017-02-19T03:27:41+00:00] ERROR: Exception handlers complete
       Chef Client failed. 0 resources updated in 02 seconds
       [2017-02-19T03:27:41+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
       [2017-02-19T03:27:41+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
       [2017-02-19T03:27:41+00:00] ERROR: "An attempt was made to change version from :latest to nil by calling version(nil). In Chef 12, this does a get rather than a set. In Chef 13, this will change to set the value to nil. (CHEF-5)/tmp/kitchen/cache/cookbooks/test/recipes/repo.rb:3:in `block in from_file'.\nPlease see https://docs.chef.io/deprecations_custom_resource_cleanups.html for further details and information on how to correct this problem. at /opt/chef/embedded/lib/ruby/gems/2.3.0/gems/chef-12.18.31/lib/chef/formatters/doc.rb:419:in `deprecation'"
       [2017-02-19T03:27:41+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
>>>>>> ------Exception-------
>>>>>> Class: Kitchen::ActionFailed
>>>>>> Message: 1 actions failed.
>>>>>>     Converge failed on instance <default-ubuntu-1604>.  Please see .kitchen/logs/default-ubuntu-1604.log for more details
>>>>>> ----------------------
>>>>>> Please see .kitchen/logs/kitchen.log for more details
>>>>>> Also try running `kitchen diagnose --all` for configuration
@tas50 tas50 mentioned this issue Feb 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant