mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-26 20:31:27 -07:00
Fix invalid string escape sequences.
This commit is contained in:
parent
6ac9d05de6
commit
9735a70059
49 changed files with 81 additions and 81 deletions
|
@ -188,7 +188,7 @@ def validate_params(module):
|
|||
|
||||
# validate function name
|
||||
if function_name.startswith('arn:'):
|
||||
if not re.search('^[\w\-]+$', function_name):
|
||||
if not re.search(r'^[\w\-]+$', function_name):
|
||||
module.fail_json(
|
||||
msg='Function name {0} is invalid. Names must contain only alphanumeric characters and hyphens.'.format(
|
||||
function_name)
|
||||
|
@ -197,7 +197,7 @@ def validate_params(module):
|
|||
module.fail_json(
|
||||
msg='Function name "{0}" exceeds 64 character limit'.format(function_name))
|
||||
else:
|
||||
if not re.search('^[\w\-:]+$', function_name):
|
||||
if not re.search(r'^[\w\-:]+$', function_name):
|
||||
module.fail_json(
|
||||
msg='ARN {0} is invalid. ARNs must contain only alphanumeric characters, hyphens and colons.'.format(function_name)
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue