ansistrano / deploy

Ansible role to deploy scripting applications like PHP, Python, Ruby, etc. in a capistrano style
https://ansistrano.com
MIT License
2.37k stars 343 forks source link

'dict object' has no attribute 'stdout' when running in --check mode #366

Closed PorridgeBear closed 3 years ago

PorridgeBear commented 4 years ago

We are seeing an error that appears only when --check mode is added.

ansible 2.9.13
  config file = /Users/name/dev/website/ansible/ansible.cfg
  configured module search path = ['/Users/name/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/local/Cellar/ansible/2.9.13/libexec/lib/python3.8/site-packages/ansible
  executable location = /usr/local/bin/ansible
  python version = 3.8.5 (default, Jul 21 2020, 10:48:26) [Clang 11.0.3 (clang-1103.0.32.62)]

With --check

TASK [ansistrano.deploy : ANSISTRANO | RSYNC | Rsync application files to remote shared copy] ************************************************************************************************************************************************
fatal: [thehost-uat]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'bool object' has no attribute 'stdout'\n\nThe error appears to be in '/Users/name/.ansible/roles/ansistrano.deploy/tasks/update-code/rsync.yml': line 6, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: ANSISTRANO | RSYNC | Rsync application files to remote shared copy\n  ^ here\n"}

And without --check, i.e. running normally:

TASK [ansistrano.deploy : ANSISTRANO | RSYNC | Rsync application files to remote shared copy] ************************************************************************************************************************************************
changed: [thehost-uat]
PorridgeBear commented 4 years ago

I've just seen this issue exists: https://github.com/ansistrano/deploy/issues/320

ricardclau commented 3 years ago

Closing as the issue already exists