diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-05 16:16:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-05 16:16:49 +0000 |
commit | 48e387c5c12026a567eb7b293a3a590241c0cecb (patch) | |
tree | 80f2573be2d7d534b8ac4d2a852fe43f7ac35324 /lib/ansible/galaxy/api.py | |
parent | Releasing progress-linux version 2.16.6-1~progress7.99u1. (diff) | |
download | ansible-core-48e387c5c12026a567eb7b293a3a590241c0cecb.tar.xz ansible-core-48e387c5c12026a567eb7b293a3a590241c0cecb.zip |
Merging upstream version 2.17.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'lib/ansible/galaxy/api.py')
-rw-r--r-- | lib/ansible/galaxy/api.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/ansible/galaxy/api.py b/lib/ansible/galaxy/api.py index af7f162..156dd4c 100644 --- a/lib/ansible/galaxy/api.py +++ b/lib/ansible/galaxy/api.py @@ -2,8 +2,7 @@ # Copyright: (c) 2019, Ansible Project # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) -from __future__ import (absolute_import, division, print_function) -__metaclass__ = type +from __future__ import annotations import collections import datetime @@ -134,6 +133,15 @@ def g_connect(versions): % (method.__name__, ", ".join(versions), ", ".join(available_versions), self.name, self.api_server)) + # Warn only when we know we are talking to a collections API + if common_versions == {'v2'}: + display.deprecated( + 'The v2 Ansible Galaxy API is deprecated and no longer supported. ' + 'Ensure that you have configured the ansible-galaxy CLI to utilize an ' + 'updated and supported version of Ansible Galaxy.', + version='2.20' + ) + return method(self, *args, **kwargs) return wrapped return decorator |