{"action":"created","issue":{"url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/53","labels_url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/53/labels{/name}","comments_url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/53/comments","events_url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/53/events","html_url":"https://github.com/opscode-cookbooks/firewall/issues/53","id":66243760,"number":53,"title":"\"No parent found for firewall_rule\" error being thrown by Poise during compile","user":{"login":"stottsan","id":266105,"avatar_url":"https://avatars.githubusercontent.com/u/266105?v=3","gravatar_id":"","url":"https://api.github.com/users/stottsan","html_url":"https://github.com/stottsan","followers_url":"https://api.github.com/users/stottsan/followers","following_url":"https://api.github.com/users/stottsan/following{/other_user}","gists_url":"https://api.github.com/users/stottsan/gists{/gist_id}","starred_url":"https://api.github.com/users/stottsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stottsan/subscriptions","organizations_url":"https://api.github.com/users/stottsan/orgs","repos_url":"https://api.github.com/users/stottsan/repos","events_url":"https://api.github.com/users/stottsan/events{/privacy}","received_events_url":"https://api.github.com/users/stottsan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-04-03T23:04:01Z","updated_at":"2015-04-04T00:02:59Z","closed_at":null,"body":"I'm seeing this error while running in DigitalOcean, but only after a number of successful Chef runs.  I can't figure out how to recover, short of building a new droplet...  This doesn't happen in Vagrant/VirtualBox at all, and it doesn't happen on initial compile/converge or the first few runs.  \r\n\r\nAny ideas?  I'm running Chef 12.2.1 on Ubuntu 14.04.2 LTS, and I'm using v1.0.1 of the firewall cookbook.  Thanks much!\r\n\r\n```\r\n================================================================================\r\nRecipe Compile Error in /var/chef/cache/cookbooks/my-tuning/recipes/default.rb\r\n================================================================================\r\n\r\nRuntimeError\r\n------------\r\nNo parent found for firewall_rule[rule-name-here]\r\n\r\nCookbook Trace:\r\n---------------\r\n  /var/chef/cache/cookbooks/poise/libraries/subresources.rb:168:in `parent'\r\n  /var/chef/cache/cookbooks/poise/libraries/subresources.rb:176:in `after_created'\r\n  /var/chef/cache/cookbooks/my-tuning/recipes/firewall.rb:18:in `block in from_file'\r\n  /var/chef/cache/cookbooks/my-tuning/recipes/firewall.rb:17:in `each'\r\n  /var/chef/cache/cookbooks/my-tuning/recipes/firewall.rb:17:in `from_file'\r\n  /var/chef/cache/cookbooks/my-tuning/recipes/default.rb:43:in `from_file'\r\n\r\nRelevant File Content:\r\n----------------------\r\n/var/chef/cache/cookbooks/poise/libraries/subresources.rb:\r\n\r\n161:          elsif !@parent\r\n162:            # Find the last instance of the parent class as the default parent\r\n163:            @run_context.resource_collection.each do |r|\r\n164:              if r.is_a?(self.class.parent_type)\r\n165:                @parent = ParentRef.new(r)\r\n166:              end\r\n167:            end\r\n168>>           raise \"No parent found for #{self}\" unless @parent || self.class.parent_optional\r\n169:          end\r\n170:          @parent && @parent.resource\r\n171:        end\r\n172:  \r\n173:        def after_created\r\n174:          super\r\n175:          begin\r\n176:            parent.subresources.lookup(self) if parent\r\n177:          rescue Chef::Exceptions::ResourceNotFound\r\n\r\n\r\nRunning handlers:\r\n[2015-04-03T18:49:18-04:00] ERROR: Running exception handlers\r\nRunning handlers complete\r\n[2015-04-03T18:49:18-04:00] ERROR: Exception handlers complete\r\n[2015-04-03T18:49:18-04:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out\r\nChef Client failed. 0 resources updated in 11.561637599 seconds\r\n[2015-04-03T18:49:18-04:00] ERROR: No parent found for firewall_rule[rule-name-here]\r\n[2015-04-03T18:49:18-04:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)\r\n```\r\n\r\n\r\nMy firewall rule (basically) is as follows:\r\n```\r\nfirewall_rule \"rule-name-here\" do\r\n    source \"1.1.1.1\"\r\n    position 1\r\n    action :reject\r\n  end\r\n``` \r\n\r\nThanks!\r\n"},"comment":{"url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/comments/89465648","html_url":"https://github.com/opscode-cookbooks/firewall/issues/53#issuecomment-89465648","issue_url":"https://api.github.com/repos/opscode-cookbooks/firewall/issues/53","id":89465648,"user":{"login":"martinb3","id":103033,"avatar_url":"https://avatars.githubusercontent.com/u/103033?v=3","gravatar_id":"","url":"https://api.github.com/users/martinb3","html_url":"https://github.com/martinb3","followers_url":"https://api.github.com/users/martinb3/followers","following_url":"https://api.github.com/users/martinb3/following{/other_user}","gists_url":"https://api.github.com/users/martinb3/gists{/gist_id}","starred_url":"https://api.github.com/users/martinb3/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martinb3/subscriptions","organizations_url":"https://api.github.com/users/martinb3/orgs","repos_url":"https://api.github.com/users/martinb3/repos","events_url":"https://api.github.com/users/martinb3/events{/privacy}","received_events_url":"https://api.github.com/users/martinb3/received_events","type":"User","site_admin":false},"created_at":"2015-04-04T00:02:59Z","updated_at":"2015-04-04T00:02:59Z","body":"Hi there -- I think this means you haven't declared a firewall resource first (or included the default recipe of this cookbook, which does that for you)."}}