From f82a2caa724af22befc4714d11a34456e4ebe858 Mon Sep 17 00:00:00 2001 From: James Cammarata Date: Fri, 10 Feb 2017 14:54:53 -0600 Subject: [PATCH] Forgot to include the utils/vars.py change with 4cbe610 --- lib/ansible/utils/vars.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/ansible/utils/vars.py b/lib/ansible/utils/vars.py index 40ad17109f..352fe08de8 100644 --- a/lib/ansible/utils/vars.py +++ b/lib/ansible/utils/vars.py @@ -20,6 +20,8 @@ from __future__ import (absolute_import, division, print_function) __metaclass__ = type import ast +import os + from json import dumps from collections import MutableMapping @@ -30,6 +32,11 @@ from ansible.errors import AnsibleError from ansible.parsing.splitter import parse_kv from ansible.module_utils._text import to_native, to_text +cur_id = 0 +def get_unique_id(): + global cur_id + cur_id += 1 + return "%s-%s" % (os.getpid(), cur_id) def _validate_mutable_mappings(a, b): """