diff options
author | Sloane Hertel <19572925+s-hertel@users.noreply.github.com> | 2023-04-18 13:02:01 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-18 12:02:01 -0500 |
commit | 2c35d46298f75098302eb9d49e943ac01cc9a7f5 (patch) | |
tree | a12881c41172e15a583f2b9b9ea37f6fc69300f1 /changelogs/fragments | |
parent | f90c7f1a7d38f317b3d22977f06ef1b15311a4a7 (diff) | |
download | ansible-2c35d46298f75098302eb9d49e943ac01cc9a7f5.tar.gz |
argspec - fix validating type for required options that are None (#79677) (#80542)
* Only bypass type validation for null parameters if the default is None. A default is mutually exclusive with required.
* Prevent coercing None to str type. Fail the type check instead.
(cherry picked from commit 694c11d5bdc7f5f7779d27315bec939dc9162ec6)
Diffstat (limited to 'changelogs/fragments')
-rw-r--r-- | changelogs/fragments/79677-fix-argspec-type-check.yml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/changelogs/fragments/79677-fix-argspec-type-check.yml b/changelogs/fragments/79677-fix-argspec-type-check.yml new file mode 100644 index 0000000000..3fe8b0f420 --- /dev/null +++ b/changelogs/fragments/79677-fix-argspec-type-check.yml @@ -0,0 +1,2 @@ +bugfixes: + - module/role argument spec - validate the type for options that are None when the option is required or has a non-None default (https://github.com/ansible/ansible/issues/79656). |