8000 jinja2 invalid syntax results in string instead of error · Issue #58282 · ansible/ansible · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
jinja2 invalid syntax results in string instead of error #58282
Closed
@agowa

Description

@agowa
SUMMARY

An invalid syntax within a jinja2 statement results in the statement being returned instead of an syntax error.

ISSUE TYPE
  • Bug Report
COMPONENT NAME

jinja2

ANSIBLE VERSION
ansible 2.9.0.dev0
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/user/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /home/user/PycharmProjects/ansible-2/lib/ansible
  executable location = /home/user/PycharmProjects/ansible-2/bin/ansible
  python version = 3.7.3 (default, Mar 26 2019, 21:43:19) [GCC 8.2.1 20181127]
CONFIGURATION
OS / ENVIRONMENT

ArchLinux

STEPS TO REPRODUCE
- name: Test
  hosts: localhost
  gather_facts: false
  become: false
  strategy: linear
  tasks:
    - debug:
        msg: "{{ foo | ipaddr('address')) }}"
EXPECTED RESULTS

Syntax error (two closing )-characters)

ACTUAL RESULTS
ok: [localhost] => {
    "msg": "{{ foo | ipaddr('address')) }}"
}

@sivel

Metadata

Metadata

Assignees

Labels

P2Priority 2 - Issue Blocks Releaseaffects_2.9This issue/PR affects Ansible v2.9bugThis issue/PR relates to a bug.support:coreThis issue/PR relates to code supported by the Ansible Engineering Team.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0