vscode-yaml icon indicating copy to clipboard operation
vscode-yaml copied to clipboard

Incorrect type. Expected "string".yaml-schema: Notify

Open balucio opened this issue 3 years ago • 2 comments

Describe the bug

Parser will signal errors in changed_when conditions

Expected Behavior

Parser should recognize correct boolean conditions in changed_when section

Current Behavior

    - name: Checking if we have to update an already present IP Address
      debug:
        msg: Calling update handler
      changed_when:
        - _ip_address_was_found
        - _ipam_ip_address_data.note != phpipam_description or _ipam_ip_address_data.hostname != phpipam_hostname
      notify: 
        - "Update IP Address"

All conditions under changed_when are marked and signaled as Incorrect type. Expected "boolean"

Steps to Reproduce

Put simple condition in changed_when section

Environment

  • [ ] Windows
  • [ ] Mac
  • [x] Linux
  • [ ] other (please specify)

balucio avatar Mar 25 '22 14:03 balucio

It is very hard for us to match a excerpt of YAML to a schema or filename. Can you please provide more details so that we can try to reproduce this?

gorkem avatar Mar 25 '22 20:03 gorkem

I'm using visual studio code and ansible plugin. Editor shons that error (incorrect type) in a perfetcly working playbook as in the example in section current Behavior

balucio avatar Mar 27 '22 13:03 balucio