diff --git a/main.yml b/main.yml index 0f231f4d..78646d97 100644 --- a/main.yml +++ b/main.yml @@ -24,7 +24,7 @@ - name: Extract ansible version from pyproject.toml set_fact: - ansible_requirement: "{{ lookup('community.general.toml', 'pyproject.toml', 'project.dependencies') | select('match', '^ansible.*') | first }}" + ansible_requirement: "{{ lookup('file', 'pyproject.toml') | regex_search('ansible==[0-9]+\\.[0-9]+\\.[0-9]+') }}" - name: Parse ansible version requirement set_fact: