diff options
author | Dag Wieers <dag@wieers.com> | 2019-02-28 21:55:18 +0100 |
---|---|---|
committer | ansibot <ansibot@users.noreply.github.com> | 2019-02-28 15:55:18 -0500 |
commit | 4e6c113bf045948ecc605870a1fec18e8a5e3d3c (patch) | |
tree | 1ddd9855a9d9753e06b853cb6cf202d147a03e18 /lib/ansible/module_utils/urls.py | |
parent | 81ec48c7b49d764a4acb1a9b5b9c9f241ab28a61 (diff) | |
download | ansible-4e6c113bf045948ecc605870a1fec18e8a5e3d3c.tar.gz |
uri/win_uri: Make method a free text field (#49719)
* uri/win_uri: Make method a free text field
Since various interfaces introduce their own HTTP method (e.g. like
PROPFIND, LIST or TRACE) it's better to leave this up to the user.
* Fix HTTP method check in module_utils urls
* Add integration test for method UNKNOWN
* Clarify the change as requested during review
Diffstat (limited to 'lib/ansible/module_utils/urls.py')
-rw-r--r-- | lib/ansible/module_utils/urls.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/lib/ansible/module_utils/urls.py b/lib/ansible/module_utils/urls.py index fd4130653b..3ae97d6b0e 100644 --- a/lib/ansible/module_utils/urls.py +++ b/lib/ansible/module_utils/urls.py @@ -1128,8 +1128,6 @@ class Request: urllib_request.install_opener(opener) data = to_bytes(data, nonstring='passthru') - if method not in ('OPTIONS', 'GET', 'HEAD', 'POST', 'PUT', 'DELETE', 'TRACE', 'CONNECT', 'PATCH'): - raise ConnectionError('invalid HTTP request method; %s' % method) request = RequestWithMethod(url, method, data) # add the custom agent header, to help prevent issues |