mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-23 13:20:23 -07:00
be explicit about urllib import and remove conditional urllib(2) import
urllib and urllib2 have been in the python stdlib since at least python-2.3. There's no reason to conditionalize it. Fixes https://github.com/ansible/ansible/issues/11322
This commit is contained in:
parent
655fa27dc7
commit
16bd2c7357
11 changed files with 23 additions and 20 deletions
|
@ -61,8 +61,7 @@ options:
|
|||
default: 'yes'
|
||||
choices: ['yes', 'no']
|
||||
|
||||
# informational: requirements for nodes
|
||||
requirements: [ urllib, urllib2 ]
|
||||
requirements: []
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
@ -72,6 +71,8 @@ EXAMPLES = '''
|
|||
revision=4.2
|
||||
'''
|
||||
|
||||
import urllib
|
||||
|
||||
# ===========================================
|
||||
# Module execution.
|
||||
#
|
||||
|
|
|
@ -72,8 +72,7 @@ options:
|
|||
choices: ['yes', 'no']
|
||||
version_added: 1.5.1
|
||||
|
||||
# informational: requirements for nodes
|
||||
requirements: [ urllib, urllib2 ]
|
||||
requirements: []
|
||||
'''
|
||||
|
||||
EXAMPLES = '''
|
||||
|
@ -83,6 +82,8 @@ EXAMPLES = '''
|
|||
revision=1.0
|
||||
'''
|
||||
|
||||
import urllib
|
||||
|
||||
# ===========================================
|
||||
# Module execution.
|
||||
#
|
||||
|
|
|
@ -76,6 +76,7 @@ EXAMPLES = '''
|
|||
comment='Test Deploy'
|
||||
'''
|
||||
|
||||
import urllib
|
||||
|
||||
def main():
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue