From 6d6d4f0c8e2b7d9a6883780d35cb56fedb8b2224 Mon Sep 17 00:00:00 2001 From: Arata Notsu Date: Tue, 1 Dec 2015 23:47:22 +0900 Subject: [PATCH] BOOLEAN should contain boolean literals It is natural that an argument_spec with choises=BOOLEAN accepts boolean literal (True, False) though the current implementation allows only string or int. --- lib/ansible/module_utils/basic.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ansible/module_utils/basic.py b/lib/ansible/module_utils/basic.py index d2cf09458e..9585733953 100644 --- a/lib/ansible/module_utils/basic.py +++ b/lib/ansible/module_utils/basic.py @@ -34,8 +34,8 @@ ANSIBLE_VERSION = "<>" MODULE_ARGS = "<>" MODULE_COMPLEX_ARGS = "<>" -BOOLEANS_TRUE = ['yes', 'on', '1', 'true', 1] -BOOLEANS_FALSE = ['no', 'off', '0', 'false', 0] +BOOLEANS_TRUE = ['yes', 'on', '1', 'true', 1, True] +BOOLEANS_FALSE = ['no', 'off', '0', 'false', 0, False] BOOLEANS = BOOLEANS_TRUE + BOOLEANS_FALSE SELINUX_SPECIAL_FS="<>"