Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

abs test overwrites built-in jinja2 abs filter #38345

Closed
wants to merge 1 commit into from

Conversation

doubleplush
Copy link
Contributor

The abs test for absolute paths overwrites the built-in Jinja2 abs
filter, preventing the absolute value of numbers from being taken and
breaking existing code which makes use of the absolute value filter.

SUMMARY

The abs test for absolute paths overwrites the built-in Jinja2 abs
filter, preventing the absolute value of numbers from being taken and
breaking existing code which makes use of the absolute value filter.

ISSUE TYPE

Bugfix Pull Request

COMPONENT NAME

abs test

ANSIBLE VERSION

affects 2.5.0 and devel

ADDITIONAL INFORMATION

ansible -m debug -a 'msg="{{ -4 | abs }}"' localhost

localhost | FAILED! => {
"msg": "Unexpected templating type error occurred on ({{ -4 | abs }}): expected str, bytes or os.PathLike object, not int"

The abs test for absolute paths overwrites the built-in Jinja2 abs
filter, preventing the absolute value of numbers from being taken and
breaking existing code which makes use of the absolute value filter.
@ansibot ansibot added bug This issue/PR relates to a bug. needs_triage Needs a first human triage before being processed. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Apr 5, 2018
@sivel
Copy link
Member

sivel commented Apr 5, 2018

This has already been resolved in #37881

If you have further questions please stop by IRC or the mailing list:

@sivel sivel closed this Apr 5, 2018
@sivel sivel removed the needs_triage Needs a first human triage before being processed. label Apr 5, 2018
@ansible ansible locked and limited conversation to collaborators Apr 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug This issue/PR relates to a bug. support:core This issue/PR relates to code supported by the Ansible Engineering Team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants