{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3567","repository_url":"https://api.github.com/repos/ansible/ansible-modules-core","labels_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3567/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3567/comments","events_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3567/events","html_url":"https://github.com/ansible/ansible-modules-core/issues/3567","id":151786975,"number":3567,"title":"os_network won't create networks: create_network() takes at most 6 arguments (7 given)","user":{"login":"JB94121","id":9011767,"avatar_url":"https://avatars.githubusercontent.com/u/9011767?v=3","gravatar_id":"","url":"https://api.github.com/users/JB94121","html_url":"https://github.com/JB94121","followers_url":"https://api.github.com/users/JB94121/followers","following_url":"https://api.github.com/users/JB94121/following{/other_user}","gists_url":"https://api.github.com/users/JB94121/gists{/gist_id}","starred_url":"https://api.github.com/users/JB94121/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JB94121/subscriptions","organizations_url":"https://api.github.com/users/JB94121/orgs","repos_url":"https://api.github.com/users/JB94121/repos","events_url":"https://api.github.com/users/JB94121/events{/privacy}","received_events_url":"https://api.github.com/users/JB94121/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/bug_report","name":"bug_report","color":"fbca04"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/cloud","name":"cloud","color":"c7def8"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/waiting_on_maintainer","name":"waiting_on_maintainer","color":"d93f0b"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2016-04-29T03:34:23Z","updated_at":"2016-08-01T19:04:22Z","closed_at":null,"body":"##### ISSUE TYPE\r\n - Bug Report\r\n\r\n\r\n##### COMPONENT NAME\r\n<!--- Name of the plugin/module/task -->\r\nos_network module\r\n\r\n##### ANSIBLE VERSION\r\nansible 2.2.0\r\n  config file = /usr/src/o3l2-ansible-installation-roles/ansible.cfg\r\n  configured module search path = Default w/o overrides\r\n\r\n##### CONFIGURATION\r\nNothing special, but still this parameters:\r\n`$ cat /usr/src/o3l2-ansible-installation-roles/ansible.cfg\r\n[defaults] \r\nlog_path=/usr/src/o3l2-ansible-installation-roles/ansible-playbook.log\r\nhost_key_checking=False\r\ntransport = paramiko\r\nforks = 50`\r\n\r\n\r\n##### OS / ENVIRONMENT\r\nN/A\r\n\r\n##### SUMMARY\r\nI am trying to provision my openstack system, and so far i have been pretty successfull by using the os_* modules: images, instances, projects, users, etc.\r\nBut for some reasons the os_network module fails with the following error:\r\n`fatal: [blade4]: FAILED! => {\"changed\": false, \"failed\": true, \"module_stderr\": \"Traceback (most recent call last):\\n  File \\\"/tmp/ansible_uvQ9ov/ansible_module_os_network.py\\\", line 246, in <module>\\n    main()\\n  File \\\"/tmp/ansible_uvQ9ov/ansible_module_os_network.py\\\", line 225, in main\\n    external, provider, project_id)\\nTypeError: create_network() takes at most 6 arguments (7 given)\\n\", \"module_stdout\": \"\", \"msg\": \"MODULE FAILURE\", \"parsed\": false}`\r\nI tried changing the number of arguments, it doesn't matter, it'll always fail the same way.\r\n\r\n##### STEPS TO REPRODUCE\r\nSystem: Red Hat 7.2\r\nInstallation of ansible 2.2.0 (issue showed up on any 2.1.0 version i tried)\r\n\r\npopulate hosts file:\r\n`...\r\n[control_nodes]\r\nblade4 ansible_host=10.0.0.2\r\n\r\n[compute_nodes]\r\nblade5 ansible_host=10.0.0.3\r\nblade6 ansible_host=10.0.0.4\r\n...\r\n`\r\n\r\nPopulate clouds.yml:\r\n`...\r\n  myopenstack-cloud2-admin:\r\n    auth:\r\n      auth_url: http://10.0.0.2:5000/v2.0/\r\n      username: admin\r\n      password: secret\r\n      project_name: admin\r\n...\r\n`\r\n\r\nCreate my file that calls roles:\r\n`- hosts: control_nodes\r\n  connection: local\r\n  remote_user: root\r\n  become: true\r\n  roles:\r\n    - 23_openstack_neutron\r\n`\r\n\r\nThen the actual role:\r\n`$ cat roles/23_openstack_neutron/tasks/main.yml `\r\n`---`\r\n`  - name: Creating provider network`\r\n`    os_network:`\r\n`      cloud: myopenstack-cloud2-admin`\r\n`      state: present`\r\n`      name: ext-net2`\r\n`      provider_network_type: vlan`\r\n`      provider_physical_network: physnet1`\r\n`      provider_segmentation_id: 3002`\r\n`      shared: yes`\r\n`      external: yes`\r\n\r\nExecute the role:\r\n`# ansible-playbook --ask-pass -i hosts -s cloud-instantiate.yml \r\n`\r\nEverything goes fine until the task of os_network is called (see error above)\r\n\r\n\r\n##### EXPECTED RESULTS\r\nNetwork should be created in neutron.\r\n\r\n##### ACTUAL RESULTS\r\n\r\n`# ansible-playbook --ask-pass -i hosts -s cloud-instantiate.yml \r\nSSH password: \r\n\r\nPLAY [control_nodes] ***********************************************************\r\n\r\nTASK [setup] *******************************************************************\r\nok: [blade4]\r\n\r\nPLAY [control_nodes] ***********************************************************\r\n\r\nTASK [setup] *******************************************************************\r\nok: [blade4]\r\n\r\nTASK [23_openstack_neutron : Creating provider network] ************************\r\nAn exception occurred during task execution. To see the full traceback, use -vvv. The error was: TypeError: create_network() takes at most 6 arguments (7 given)\r\nfatal: [blade4]: FAILED! => {\"changed\": false, \"failed\": true, \"module_stderr\": \"Traceback (most recent call last):\\n  File \\\"/tmp/ansible_ahjffA/ansible_module_os_network.py\\\", line 246, in <module>\\n    main()\\n  File \\\"/tmp/ansible_ahjffA/ansible_module_os_network.py\\\", line 225, in main\\n    external, provider, project_id)\\nTypeError: create_network() takes at most 6 arguments (7 given)\\n\", \"module_stdout\": \"\", \"msg\": \"MODULE FAILURE\", \"parsed\": false}\r\n\r\nNO MORE HOSTS LEFT *************************************************************\r\n\tto retry, use: --limit @cloud-instantiate.retry\r\n\r\nPLAY RECAP *********************************************************************\r\nblade4                     : ok=2    changed=0    unreachable=0    failed=1   `"},"comment":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/comments/236675392","html_url":"https://github.com/ansible/ansible-modules-core/issues/3567#issuecomment-236675392","issue_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/3567","id":236675392,"user":{"login":"Shrews","id":925883,"avatar_url":"https://avatars.githubusercontent.com/u/925883?v=3","gravatar_id":"","url":"https://api.github.com/users/Shrews","html_url":"https://github.com/Shrews","followers_url":"https://api.github.com/users/Shrews/followers","following_url":"https://api.github.com/users/Shrews/following{/other_user}","gists_url":"https://api.github.com/users/Shrews/gists{/gist_id}","starred_url":"https://api.github.com/users/Shrews/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shrews/subscriptions","organizations_url":"https://api.github.com/users/Shrews/orgs","repos_url":"https://api.github.com/users/Shrews/repos","events_url":"https://api.github.com/users/Shrews/events{/privacy}","received_events_url":"https://api.github.com/users/Shrews/received_events","type":"User","site_admin":false},"created_at":"2016-08-01T19:04:22Z","updated_at":"2016-08-01T19:04:22Z","body":"Unfortunately, I have no way to reproduce this error. Are you still experiencing this error? And have you tried it with the latest versions of shade and Ansible?\r\n\r\nneeds_info"}}
{"actor":{"display_login":"Shrews"}}