{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/43015","repository_url":"https://api.github.com/repos/ansible/ansible","labels_url":"https://api.github.com/repos/ansible/ansible/issues/43015/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/43015/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/43015/events","html_url":"https://github.com/ansible/ansible/issues/43015","id":342705886,"node_id":"MDU6SXNzdWUzNDI3MDU4ODY=","number":43015,"title":" Python3 YAML inventory parsing error","user":{"login":"ITD27M01","id":3703483,"node_id":"MDQ6VXNlcjM3MDM0ODM=","avatar_url":"https://avatars2.githubusercontent.com/u/3703483?v=4","gravatar_id":"","url":"https://api.github.com/users/ITD27M01","html_url":"https://github.com/ITD27M01","followers_url":"https://api.github.com/users/ITD27M01/followers","following_url":"https://api.github.com/users/ITD27M01/following{/other_user}","gists_url":"https://api.github.com/users/ITD27M01/gists{/gist_id}","starred_url":"https://api.github.com/users/ITD27M01/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ITD27M01/subscriptions","organizations_url":"https://api.github.com/users/ITD27M01/orgs","repos_url":"https://api.github.com/users/ITD27M01/repos","events_url":"https://api.github.com/users/ITD27M01/events{/privacy}","received_events_url":"https://api.github.com/users/ITD27M01/received_events","type":"User","site_admin":false},"labels":[{"id":835286067,"node_id":"MDU6TGFiZWw4MzUyODYwNjc=","url":"https://api.github.com/repos/ansible/ansible/labels/affects_2.6","name":"affects_2.6","color":"ededed","default":false},{"id":785271699,"node_id":"MDU6TGFiZWw3ODUyNzE2OTk=","url":"https://api.github.com/repos/ansible/ansible/labels/bug","name":"bug","color":"fbca04","default":true},{"id":612318497,"node_id":"MDU6TGFiZWw2MTIzMTg0OTc=","url":"https://api.github.com/repos/ansible/ansible/labels/inventory","name":"inventory","color":"1d76db","default":false},{"id":383076471,"node_id":"MDU6TGFiZWwzODMwNzY0NzE=","url":"https://api.github.com/repos/ansible/ansible/labels/python3","name":"python3","color":"fbca04","default":false},{"id":636352796,"node_id":"MDU6TGFiZWw2MzYzNTI3OTY=","url":"https://api.github.com/repos/ansible/ansible/labels/support:core","name":"support:core","color":"ededed","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-07-19T12:23:57Z","updated_at":"2018-07-22T12:48:26Z","closed_at":"2018-07-22T12:47:53Z","author_association":"NONE","body":"<!---\r\nVerify first that your issue/request is not already reported on GitHub.\r\nTHIS FORM WILL BE READ BY A MACHINE, COMPLETE ALL SECTIONS AS DESCRIBED.\r\nAlso test if the latest release, and devel branch are affected too.\r\nALWAYS add information AFTER (OUTSIDE) these html comments.\r\nOtherwise it may end up being automatically closed by our bot. -->\r\n\r\n##### SUMMARY\r\n<!--- Explain the problem briefly -->\r\nyaml file does not parsed not loaded by ansible 2.6.1 as inventory source\r\n##### ISSUE TYPE\r\n - Bug Report\r\n\r\n##### COMPONENT NAME\r\n<!--- Insert, BELOW THIS COMMENT, the name of the module, plugin, task or feature.\r\nDo not include extra details here, e.g. \"vyos_command\" not \"the network module vyos_command\" or the full path-->\r\ninventory\r\n##### ANSIBLE VERSION\r\n<!--- Paste, BELOW THIS COMMENT, verbatim output from \"ansible --version\" between quotes below -->\r\n```\r\nansible 2.6.1\r\n  config file = /root/ansible/ansible.cfg\r\n  configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']\r\n  ansible python module location = /opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/ansible\r\n  executable location = /opt/rh/rh-python36/root/usr/bin/ansible\r\n  python version = 3.6.3 (default, Jan  9 2018, 10:19:07) [GCC 4.8.5 20150623 (Red Hat 4.8.5-11)]\r\n```\r\n\r\n##### CONFIGURATION\r\n<!--- If using Ansible 2.4 or above, paste, BELOW THIS COMMENT, the results of \"ansible-config dump --only-changed\"\r\nOtherwise, mention any settings you have changed/added/removed in ansible.cfg\r\n(or using the ANSIBLE_* environment variables).-->\r\n```\r\nDEFAULT_HOST_LIST(/root/ansible/ansible.cfg) = ['/root/ansible/inventory']\r\n```\r\n##### OS / ENVIRONMENT\r\n<!--- Mention, BELOW THIS COMMENT, the OS you are running Ansible from, and the OS you are\r\nmanaging, or say \"N/A\" for anything that is not platform-specific.\r\nAlso mention the specific version of what you are trying to control,\r\ne.g. if this is a network bug the version of firmware on the network device.-->\r\nRed Hat Enterprise Linux Server release 7.5 (Maipo)\r\npython36 from software collection\r\n##### STEPS TO REPRODUCE\r\n<!--- For bugs, show exactly how to reproduce the problem, using a minimal test-case.\r\nFor new features, show how the feature would be used. -->\r\n1. Create inventory/production.yaml file with content:\r\n```yaml\r\n---\r\nall:\r\n  hosts:\r\n    localhost:\r\n      ansible_connection: local\r\n...\r\n``` \r\n2. Try to ping localhost:\r\nansible localhost -m ping \r\n3. Get the warning\r\n\r\n```\r\n> ansible localhost -m ping                            \r\n [WARNING]:  * Failed to parse /root/ansible/inventory/production.yaml with ini plugin: b'/root/ansible/inventory/production.yaml':5: Expected key=value\r\nhost variable assignment, got: local\r\n\r\n [WARNING]: Unable to parse /root/ansible/inventory/production.yaml as an inventory source\r\n\r\n [WARNING]: Unable to parse /root/ansible/inventory as an inventory source\r\n\r\n [WARNING]: No inventory was parsed, only implicit localhost is available\r\n\r\nlocalhost | SUCCESS => {\r\n    \"changed\": false,\r\n    \"ping\": \"pong\"\r\n}\r\n```\r\n\r\n\r\n<!--- You can also paste gist.github.com links for larger files -->\r\n\r\n##### EXPECTED RESULTS\r\n<!--- What did you expect to happen when running the steps above? -->\r\nyaml inventory parsed \r\n##### ACTUAL RESULTS\r\n<!--- What actually happened? If possible run with extra verbosity (-vvvv) -->\r\nUnable to parse yaml as an inventory source\r\n<!--- Paste verbatim command output between quotes below -->\r\n\r\n\r\nOnly 2.6.1 is affected. 2.5.5 and below works as expected."},"comment":{"url":"https://api.github.com/repos/ansible/ansible/issues/comments/406864173","html_url":"https://github.com/ansible/ansible/issues/43015#issuecomment-406864173","issue_url":"https://api.github.com/repos/ansible/ansible/issues/43015","id":406864173,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNjg2NDE3Mw==","user":{"login":"sivel","id":39340,"node_id":"MDQ6VXNlcjM5MzQw","avatar_url":"https://avatars3.githubusercontent.com/u/39340?v=4","gravatar_id":"","url":"https://api.github.com/users/sivel","html_url":"https://github.com/sivel","followers_url":"https://api.github.com/users/sivel/followers","following_url":"https://api.github.com/users/sivel/following{/other_user}","gists_url":"https://api.github.com/users/sivel/gists{/gist_id}","starred_url":"https://api.github.com/users/sivel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sivel/subscriptions","organizations_url":"https://api.github.com/users/sivel/orgs","repos_url":"https://api.github.com/users/sivel/repos","events_url":"https://api.github.com/users/sivel/events{/privacy}","received_events_url":"https://api.github.com/users/sivel/received_events","type":"User","site_admin":false},"created_at":"2018-07-22T12:48:26Z","updated_at":"2018-07-22T12:48:26Z","author_association":"MEMBER","body":"Duplicate of https://github.com/ansible/ansible/issues/42118"}}
{"actor":{"display_login":"sivel"}}