Build wheels depending on presence of venv_build_group

In case venv_build_group is not present in inventory or does not contain
a single host, it does not make sense to attept building wheels.

With that we're changing default behaviour to avoid building wheels
if there're no potential targets exists.

Change-Id: Ifd0e80dd1d1f002a1b80f57b53b81ca9110e719c
This commit is contained in:
Dmitriy Rabotyagov 2023-05-24 14:38:19 +02:00 committed by Dmitriy Rabotyagov
parent e24c1a4f71
commit 01a08f39bb
2 changed files with 5 additions and 3 deletions

View File

@ -122,7 +122,7 @@ venv_wheels_rebuild: no
# If the package concerned is built from a tarball, rather
# than from a git source or pypi, then this may be best to
# set to false.
venv_wheel_build_enable: True
venv_wheel_build_enable: "{{ (venv_build_group in groups and groups[venv_build_group] | length > 0) }}"
# Set the name of the ansible group, that will be used
# to identify suitable host to build wheels on

View File

@ -1,5 +1,7 @@
---
other:
- |
Default value of ``venv_wheel_build_enable`` has been changed to True.
Previously it was depending on amount of hosts targeted for the play.
Default value of ``venv_wheel_build_enable`` has been changed. Now
wheels are built when there is at least a single host in
``venv_build_group``.
Previously it was depending on the amount of hosts targeted for the play.