diff options
author | Alexei Znamensky <103110+russoz@users.noreply.github.com> | 2021-03-01 16:40:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-01 16:40:38 +0100 |
commit | 920b68f5f25adda201549e46afdb8d6282eb1871 (patch) | |
tree | da5c799ac9d6d5bdb4d53c7e29afe7775ea04b19 /lib | |
parent | Let file module not change link to absolute when src not given (#65448) (diff) | |
download | ansible-920b68f5f25adda201549e46afdb8d6282eb1871.tar.xz ansible-920b68f5f25adda201549e46afdb8d6282eb1871.zip |
Fixed/improved regular expresssion for collection names (#73577)
* added changelog fragment
* added a couple of tests to coll name validation
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ansible/utils/collection_loader/_collection_finder.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ansible/utils/collection_loader/_collection_finder.py b/lib/ansible/utils/collection_loader/_collection_finder.py index be9c07e264..393ddbee7b 100644 --- a/lib/ansible/utils/collection_loader/_collection_finder.py +++ b/lib/ansible/utils/collection_loader/_collection_finder.py @@ -701,7 +701,7 @@ class AnsibleCollectionRef: # FIXME: tighten this up to match Python identifier reqs, etc VALID_SUBDIRS_RE = re.compile(to_text(r'^\w+(\.\w+)*$')) - VALID_FQCR_RE = re.compile(to_text(r'^\w+\.\w+\.\w+(\.\w+)*$')) # can have 0-N included subdirs as well + VALID_FQCR_RE = re.compile(to_text(r'^\w+(\.\w+){2,}$')) # can have 0-N included subdirs as well def __init__(self, collection_name, subdirs, resource, ref_type): """ |