aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCy Schubert <cy@FreeBSD.org>2024-05-15 18:00:36 +0000
committerCy Schubert <cy@FreeBSD.org>2024-05-15 22:08:48 +0000
commit5be809dfd0b2469a26aa43e91e43ae4590d988f9 (patch)
treed08b1d7f3d91ba9e11f55f59c696dbc7889505b8
parentc51c31615954c13b4427f849e6cf20fd936953e3 (diff)
downloadports-5be809dfd0b2469a26aa43e91e43ae4590d988f9.tar.gz
ports-5be809dfd0b2469a26aa43e91e43ae4590d988f9.zip
sysutils/ansible: Chase 58df5a82adc40a6959e9b22c, net/py-netaddr update
net/py-netaddr 1.2.1 deprecated and removed the is_private method. This breaks ansible-collections which is bundled this port's tarball. The upstream patch uses the is_global methhod instead. Reported by: Einar Bjarni Halldorsson <einar@isnic.is> Obtained from: https://github.com/ansible-collections/ansible.utils/pull/338 (cherry picked from commit 698ed6d9b68169e3a5549fe2abf1a13bad5a653b)
-rw-r--r--sysutils/ansible/Makefile1
-rw-r--r--sysutils/ansible/files/patch-ansible__collections_ansible_utils_plugins_plugin__utils_base_ipaddr_utils.py20
2 files changed, 21 insertions, 0 deletions
diff --git a/sysutils/ansible/Makefile b/sysutils/ansible/Makefile
index d8c4c8e2bcac..e0d5c757c25c 100644
--- a/sysutils/ansible/Makefile
+++ b/sysutils/ansible/Makefile
@@ -1,5 +1,6 @@
PORTNAME= ansible
DISTVERSION= 8.5.0
+PORTREVISION= 1
CATEGORIES= sysutils python
MASTER_SITES= PYPI
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
diff --git a/sysutils/ansible/files/patch-ansible__collections_ansible_utils_plugins_plugin__utils_base_ipaddr_utils.py b/sysutils/ansible/files/patch-ansible__collections_ansible_utils_plugins_plugin__utils_base_ipaddr_utils.py
new file mode 100644
index 000000000000..e89669b4830c
--- /dev/null
+++ b/sysutils/ansible/files/patch-ansible__collections_ansible_utils_plugins_plugin__utils_base_ipaddr_utils.py
@@ -0,0 +1,20 @@
+--- ansible_collections/ansible/utils/plugins/plugin_utils/base/ipaddr_utils.py.orig 2023-09-07 02:17:47.000000000 -0700
++++ ansible_collections/ansible/utils/plugins/plugin_utils/base/ipaddr_utils.py 2024-05-15 08:23:34.190190000 -0700
+@@ -289,7 +289,7 @@
+
+
+ def _private_query(v, value):
+- if v.is_private():
++ if not v.ip.is_global():
+ return value
+
+
+@@ -298,7 +298,7 @@
+ if all(
+ [
+ v_ip.is_unicast(),
+- not v_ip.is_private(),
++ v_ip.is_global(),
+ not v_ip.is_loopback(),
+ not v_ip.is_netmask(),
+ not v_ip.is_hostmask(),