Skip to content
This repository was archived by the owner on Oct 30, 2018. It is now read-only.
This repository was archived by the owner on Oct 30, 2018. It is now read-only.

stat.exists regression #5115

@php-coder

Description

@php-coder
ISSUE TYPE
  • Bug Report
COMPONENT NAME

stat

ANSIBLE VERSION
2.1.2.0
OS / ENVIRONMENT

Travis CI

SUMMARY

My playbook that tries to check whether file exists or not started to fails with ansible 2.1.2.0 release. It worked on 2.1.1.0 version.

STEPS TO REPRODUCE
  - name: Getting info about WAR file
    stat:
      path: 'target/mystamps.war'
      get_checksum: no
      get_md5: no
    register: war_file
    become: no
    delegate_to: 127.0.0.1

  - name: Ensuring that WAR file exists
    assert:
      that:
        war_file.stat.exists
    become: no
    delegate_to: 127.0.0.1
EXPECTED RESULTS
TASK [Getting info about WAR file] *********************************************
ok: [my-stamps.ru -> 127.0.0.1]
TASK [Ensuring that WAR file exists] *******************************************
ok: [my-stamps.ru -> 127.0.0.1]
ACTUAL RESULTS
TASK [Getting info about WAR file] *********************************************
ok: [my-stamps.ru -> 127.0.0.1]
TASK [Ensuring that WAR file exists] *******************************************
fatal: [my-stamps.ru -> 127.0.0.1]: FAILED! => {"assertion": "war_file.stat.exists", "changed": false, "evaluated_to": false, "failed": true}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions