{"action":"created","issue":{"url":"https://api.github.com/repos/rodjek/puppet-lint/issues/424","repository_url":"https://api.github.com/repos/rodjek/puppet-lint","labels_url":"https://api.github.com/repos/rodjek/puppet-lint/issues/424/labels{/name}","comments_url":"https://api.github.com/repos/rodjek/puppet-lint/issues/424/comments","events_url":"https://api.github.com/repos/rodjek/puppet-lint/issues/424/events","html_url":"https://github.com/rodjek/puppet-lint/issues/424","id":86600418,"number":424,"title":"Hash of hashes with long keys causes irrational warnings and crashes --fix","user":{"login":"TomOnTime","id":1389289,"avatar_url":"https://avatars.githubusercontent.com/u/1389289?v=3","gravatar_id":"","url":"https://api.github.com/users/TomOnTime","html_url":"https://github.com/TomOnTime","followers_url":"https://api.github.com/users/TomOnTime/followers","following_url":"https://api.github.com/users/TomOnTime/following{/other_user}","gists_url":"https://api.github.com/users/TomOnTime/gists{/gist_id}","starred_url":"https://api.github.com/users/TomOnTime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TomOnTime/subscriptions","organizations_url":"https://api.github.com/users/TomOnTime/orgs","repos_url":"https://api.github.com/users/TomOnTime/repos","events_url":"https://api.github.com/users/TomOnTime/events{/privacy}","received_events_url":"https://api.github.com/users/TomOnTime/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2015-06-09T13:29:53Z","updated_at":"2016-06-25T14:57:59Z","closed_at":"2016-06-25T04:12:14Z","body":"`puppet-lint --fix example.pp` crashes with this code.\r\n\r\n```\r\n#\r\nclass example (\r\n  $tiername,\r\n  $external_ip_base,\r\n) {\r\n  stacklb::external::ssl_listener { \"${tiername}-1\":\r\n    id     => 1,\r\n    inputs => {\r\n      'ny' => {\r\n        \"${external_ip_base}.16:443\"  => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.17:443\"  => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.30:443\"  => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.18:443\"  => $stacklb::external::params::ssl_wc_san,\r\n        '10.0.0.10:443'               => $stacklb::external::params::ssl_wc_se_internal,\r\n        \"${external_ip_base}.24:443\"  => $stacklb::external::params::ssl_misc,\r\n        \"${external_ip_base}.140:443\" => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.141:443\" => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.154:443\" => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.142:443\" => $stacklb::external::params::ssl_wc_san,\r\n        \"${external_ip_base}.148:443\" => $stacklb::external::params::ssl_misc,\r\n      },\r\n      'or' => {\r\n        '10.10.100.16:443' => $stacklb::external::params::ssl_wc_san,\r\n        '10.10.100.17:443' => $stacklb::external::params::ssl_wc_san,\r\n        '10.10.100.30:443' => $stacklb::external::params::ssl_wc_san,\r\n        '10.10.100.18:443' => $stacklb::external::params::ssl_wc_san,\r\n        '10.0.0.10:443'    => $stacklb::external::params::ssl_wc_se_internal,\r\n        '10.10.100.24:443' => $stacklb::external::params::ssl_misc,\r\n      }\r\n    }\r\n  }\r\n}\r\n```\r\n\r\nWithout `--fix` you get conflicting requirements.  As-is, it gives these warnings:\r\n\r\n```\r\n$ puppet-lint   example.pp \r\nERROR: example not in autoload module layout on line 2\r\nWARNING: indentation of => is not properly aligned on line 10\r\nWARNING: indentation of => is not properly aligned on line 11\r\nWARNING: indentation of => is not properly aligned on line 12\r\nWARNING: indentation of => is not properly aligned on line 13\r\nWARNING: indentation of => is not properly aligned on line 14\r\nWARNING: indentation of => is not properly aligned on line 15\r\nWARNING: indentation of => is not properly aligned on line 16\r\nWARNING: indentation of => is not properly aligned on line 17\r\nWARNING: indentation of => is not properly aligned on line 18\r\nWARNING: indentation of => is not properly aligned on line 19\r\nWARNING: indentation of => is not properly aligned on line 20\r\nWARNING: line has more than 80 characters on line 14\r\n```\r\n\r\nI hacked puppet-lint to expose what alignment it was expecting.  When I aligned things that way, it warned me that this alignment was incorrect too.  No wonder --fix crashes."},"comment":{"url":"https://api.github.com/repos/rodjek/puppet-lint/issues/comments/228548278","html_url":"https://github.com/rodjek/puppet-lint/issues/424#issuecomment-228548278","issue_url":"https://api.github.com/repos/rodjek/puppet-lint/issues/424","id":228548278,"user":{"login":"TomOnTime","id":1389289,"avatar_url":"https://avatars.githubusercontent.com/u/1389289?v=3","gravatar_id":"","url":"https://api.github.com/users/TomOnTime","html_url":"https://github.com/TomOnTime","followers_url":"https://api.github.com/users/TomOnTime/followers","following_url":"https://api.github.com/users/TomOnTime/following{/other_user}","gists_url":"https://api.github.com/users/TomOnTime/gists{/gist_id}","starred_url":"https://api.github.com/users/TomOnTime/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TomOnTime/subscriptions","organizations_url":"https://api.github.com/users/TomOnTime/orgs","repos_url":"https://api.github.com/users/TomOnTime/repos","events_url":"https://api.github.com/users/TomOnTime/events{/privacy}","received_events_url":"https://api.github.com/users/TomOnTime/received_events","type":"User","site_admin":false},"created_at":"2016-06-25T14:57:59Z","updated_at":"2016-06-25T14:57:59Z","body":"@rnelson0 P.S. I don't see how to re-open the issue. (sorry!)"}}
{"actor":{"display_login":"TomOnTime"}}