{"action":"opened","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/30447","repository_url":"https://api.github.com/repos/ansible/ansible","labels_url":"https://api.github.com/repos/ansible/ansible/issues/30447/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/30447/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/30447/events","html_url":"https://github.com/ansible/ansible/issues/30447","id":258179502,"number":30447,"title":"include_items + with_items = Deprecation Message","user":{"login":"paulcalabro","id":585059,"avatar_url":"https://avatars1.githubusercontent.com/u/585059?v=4","gravatar_id":"","url":"https://api.github.com/users/paulcalabro","html_url":"https://github.com/paulcalabro","followers_url":"https://api.github.com/users/paulcalabro/followers","following_url":"https://api.github.com/users/paulcalabro/following{/other_user}","gists_url":"https://api.github.com/users/paulcalabro/gists{/gist_id}","starred_url":"https://api.github.com/users/paulcalabro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paulcalabro/subscriptions","organizations_url":"https://api.github.com/users/paulcalabro/orgs","repos_url":"https://api.github.com/users/paulcalabro/repos","events_url":"https://api.github.com/users/paulcalabro/events{/privacy}","received_events_url":"https://api.github.com/users/paulcalabro/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-09-15T22:23:23Z","updated_at":"2017-09-15T22:23:23Z","closed_at":null,"author_association":"NONE","body":"ISSUE TYPE:  Bug Report\r\n\r\nCOMPONENT NAME: include_tasks, with items\r\n\r\nANSIBLE VERSION: 2.5.0\r\n\r\nCONFIGURATION: I can provide this if needed\r\n\r\nOS / ENVIRONMENT: OSX 10.12.6\r\n\r\nSUMMARY: A deprecation message is shown regarding the usage of with_items when using include_tasks. \r\n\r\nFrom http://docs.ansible.com/ansible/devel/playbooks_reuse.html:\r\n\r\n```\r\n...\r\nThe primary advantage of using include* statements is looping. When a loop is used with an include, the included tasks or role will be executed once for each item in the loop.\r\n...\r\n```\r\n\r\nSTEPS TO REPRODUCE:\r\n\r\n`ansible-playbook -i production-servers site.yml -K`\r\n\r\n```\r\n   ...\r\n    - name: 'Authorize passwordless logins'\r\n      include_tasks: 'roles/ssh/tasks/update_authorized_keys.yml'\r\n      with_tems:\r\n        - {user: 'some_account', filename: 'some_file'}\r\n    ...\r\n\r\n```\r\n```\r\n[DEPRECATION WARNING]: Specifying include variables at the top-level of the task is deprecated. Please see:\r\nhttp://docs.ansible.com/ansible/playbooks_roles.html#task-include-files-and-encouraging-reuse   for currently supported syntax\r\nregarding included files and variables. This feature will be removed in version 2.7. Deprecation warnings can be disabled by\r\nsetting deprecation_warnings=False in ansible.cfg.\r\n```\r\n\r\nEXPECTED RESULTS:\r\nProcessing of each item within the included task list\r\n\r\nACTUAL RESULTS:  a deprecation message"}}
{"actor":{"display_login":"paulcalabro"}}