ansible-galaxy collection install dep resolver changes #71784
Labels
affects_2.11
feature
This issue/PR relates to a feature request.
has_pr
This issue has an associated PR.
support:core
This issue/PR relates to code supported by the Ansible Engineering Team.
SUMMARY
The current dep resolver for
ansible-galaxy collection install
does not handle updating of collections too well. The current behaviour will never upgrade an already installed collection even if a newer one was available. If a version constraint was specified that the current collection does not meet then it will error saying--force
(--force-with-deps
for dep conflicts) is required. The--force
argument has it's own problem and acts like a sledgehammer removing all the collections and starting again. To prepare for adding the--upgrade
flag toinstall
we first need to fix this behaviour. The following changes need to be made to how the dep resolver works--force
--force-with-deps
The relevant tests will need to be updated and an integration test added for these 2 scenario changes. The _build_dependency_map function is a good starting point for this.
ISSUE TYPE
COMPONENT NAME
ansible-galaxy collection install
ADDITIONAL INFORMATION
The new dep resolver behaviour is planned to act like
pip
. Some test scenarios for pip can be found at https://gist.github.com/jborean93/65495d1e36aa9c02fbdf707d4232fff7.The text was updated successfully, but these errors were encountered: