Issue 1:
ISSUE TYPE

Bug Report

COMPONENT NAME

include_vars

ANSIBLE VERSION

$ ansible --version
ansible 2.4.0.0
config file = None
configured module search path = [u'/home/vagrant/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.5 (default, Aug 4 2017, 00:39:18) [GCC 4.8.5 20150623 (Red Hat 4.8.5-16)]

CONFIGURATION

$ ansible-config dump --only-changed
# nothing

OS / ENVIRONMENT

Centos 7 (Vagrantfile below)

SUMMARY

include_vars: dir inside a role is only searching relative to the role. The docs suggest it also searches relative to the playbook. Either it's not searching both the owning role and the playbook directory, or the docs are wrong.

STEPS TO REPRODUCE

I've put everything into a repo; you can clone it and duplicate the problem.

role2/tasks/main.yml:

- include_vars:
dir: role1

- debug:
var: role1_var

EXPECTED RESULTS

"role1_var": "This is from role 1"

ACTUAL RESULTS

A complete log is in the repo; the specific problem is below:

"{{ playbook_dir }}/roles/role2/vars/role1 directory does not exist"

Issue 2:
ISSUE TYPE

Bug Report

COMPONENT NAME

azure_rm_virtualmachine

ANSIBLE VERSION

ansible 2.4.3.0
config file = /home/admin/Code/ansible/ansible.cfg
configured module search path = [u'/home/admin/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python2.7/site-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.14 (default, Jan 5 2018, 10:41:29) [GCC 7.2.1 20171224]

CONFIGURATION

DEFAULT_VAULT_PASSWORD_FILE(/home/admin/Code/ansible/ansible.cfg) = /home/admin/Code/ansible/.vault_pass
RETRY_FILES_ENABLED(/home/admin/Code/ansible/ansible.cfg) = False

OS / ENVIRONMENT

Arch Linux

SUMMARY

Deserialization error against the python sdk when attempting to create a virtual machine.

STEPS TO REPRODUCE

- name: Create {{vm_web_name}} virtual machine
azure_rm_virtualmachine:
client_id: "{{azure_client_id}}"
secret: "{{azure_secret}}"
tenant: "{{azure_tenant}}"
subscription_id: "{{azure_subscription}}"
resource_group: "{{resource_group_name}}"
name: "{{vm_web_name}}"
admin_username: "{{vm_web_username}}"
image:
offer: "{{vm_web_image_offer}}"
publisher: "{{vm_web_image_publisher}}"
sku: "{{vm_web_image_sku}}"
version: "{{vm_web_image_version}}"
location: "{{vm_web_location}}"
managed_disk_type: "Standard_LRS"
network_interface_names: "{{nic_web_name}}"
ssh_password_enabled: False
ssh_public_keys:
- path: "/home/{{vm_web_username}}/.ssh/authorized_keys"
key_data: "{{vm_web_ssh}}"
vm_size: "{{vm_web_size}}"
state: present

EXPECTED RESULTS

VM gets created

ACTUAL RESULTS

The full traceback is:
File "/tmp/ansible_9a4xdcrg/ansible_module_azure_rm_virtualmachine.py", line 1353, in create_or_update_vm
poller = self.compute_client.virtual_machines.create_or_update(self.resource_group, self.name, params)
File "/usr/lib/python3.6/site-packages/azure/mgmt/compute/v2017_03_30/operations/virtual_machines_operations.py", line 242, in create_or_update
**operation_config
File "/usr/lib/python3.6/site-packages/azure/mgmt/compute/v2017_03_30/operations/virtual_machines_operations.py", line 189, in _create_or_update_initial
body_content = self._serialize.body(parameters, 'VirtualMachine')
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 452, in body
SerializationError, "Unable to build a model: "+str(err), err)
File "/usr/lib/python3.6/site-packages/msrest/exceptions.py", line 45, in raise_with_traceback
raise error.with_traceback(exc_traceback)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 449, in body
data = deserializer(data_type, data)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 973, in __call__
self(local_type, value)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 973, in __call__
self(local_type, value)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 973, in __call__
self(local_type, value)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 985, in __call__
return self.deserialize_enum(data, response)
File "/usr/lib/python3.6/site-packages/msrest/serialization.py", line 1296, in deserialize_enum
raise DeserializationError(error.format(data, enum_obj))

"msg": "Error creating or updating virtual machine VM-Web-PythonWeb - Unable to build a model: <DiskCreateOptionTypes.from_image: 'FromImage'> is not valid value for enum <enum 'DiskCreateOptionTypes'>, DeserializationError: <DiskCreateOptionTypes.from_image: 'FromImage'> is not valid value for enum <enum 'DiskCreateOptionTypes'>"

Extra info

I did some debugging and got this

{'id': None, 'name': None, 'type': None, 'location': 'westeurope', 'tags': None, 'plan': None, 'hardware_profile':
<azure.mgmt.compute.v2017_12_01.models.hardware_profile.HardwareProfile object at 0x7fad68594550>, 'storage_profile':
<azure.mgmt.compute.v2017_12_01.models.storage_profile.StorageProfile object at 0x7fad685946a0>, 'os_profile':
<azure.mgmt.compute.v2017_12_01.models.os_profile.OSProfile object at 0x7fad687efac8>, 'network_profile':
<azure.mgmt.compute.v2017_12_01.models.network_profile.NetworkProfile object at 0x7fad685945f8>, 'diagnostics_profile': None, 'availability_set': None,
'provisioning_state': None, 'instance_view': None, 'license_type': None, 'vm_id': None, 'resources': None, 'identity': None, 'zones': None}

which looks like its using compute client models from v2017_12_01

however it looks like the compute_client we are using is v2017_03_03

https://github.com/ansible/ansible/blob/devel/lib/ansible/module_utils/azure_rm_common.py#L910

I changed it to 2017-12-01 and it worked for me.