From 42194f562e244c506d99b953e039691c3c02258f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= Date: Sun, 8 Jun 2025 18:25:59 -0300 Subject: [PATCH] python3-networkx: update to 3.5. --- ...b527998dcc9077f704848e48538020e36098.patch | 35 +++++++++++++++++++ srcpkgs/python3-networkx/template | 6 ++-- 2 files changed, 38 insertions(+), 3 deletions(-) create mode 100644 srcpkgs/python3-networkx/patches/05c7b527998dcc9077f704848e48538020e36098.patch diff --git a/srcpkgs/python3-networkx/patches/05c7b527998dcc9077f704848e48538020e36098.patch b/srcpkgs/python3-networkx/patches/05c7b527998dcc9077f704848e48538020e36098.patch new file mode 100644 index 00000000000..3d8e132ded6 --- /dev/null +++ b/srcpkgs/python3-networkx/patches/05c7b527998dcc9077f704848e48538020e36098.patch @@ -0,0 +1,35 @@ +Taken from https://github.com/networkx/networkx/pull/8096 + +From 05c7b527998dcc9077f704848e48538020e36098 Mon Sep 17 00:00:00 2001 +From: Ross Barnowski +Date: Tue, 3 Jun 2025 13:05:37 -0700 +Subject: [PATCH] Fix gh-8091 + +--- + networkx/generators/lattice.py | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/networkx/generators/lattice.py b/networkx/generators/lattice.py +index 95e520d2ce1..0617cd2bf7a 100644 +--- a/networkx/generators/lattice.py ++++ b/networkx/generators/lattice.py +@@ -124,15 +124,15 @@ def grid_graph(dim, periodic=False): + >>> len(G) + 6 + """ ++ from collections.abc import Iterable ++ + from networkx.algorithms.operators.product import cartesian_product + + if not dim: + return empty_graph(0) + +- try: +- func = (cycle_graph if p else path_graph for p in periodic) +- except TypeError: +- func = repeat(cycle_graph if periodic else path_graph) ++ periodic = repeat(periodic) if not isinstance(periodic, Iterable) else periodic ++ func = (cycle_graph if p else path_graph for p in periodic) + + G = next(func)(dim[0]) + for current_dim in dim[1:]: diff --git a/srcpkgs/python3-networkx/template b/srcpkgs/python3-networkx/template index 12d7ec71e36..65c8a8c03a0 100644 --- a/srcpkgs/python3-networkx/template +++ b/srcpkgs/python3-networkx/template @@ -1,7 +1,7 @@ # Template file for 'python3-networkx' pkgname=python3-networkx -version=3.4.2 -revision=2 +version=3.5 +revision=1 build_style=python3-pep517 hostmakedepends="python3-setuptools python3-wheel" depends="python3" @@ -13,7 +13,7 @@ license="BSD-3-Clause" homepage="https://networkx.org" changelog="https://github.com/networkx/networkx/raw/main/doc/release/release_${version}.rst" distfiles="${PYPI_SITE}/n/networkx/networkx-${version}.tar.gz" -checksum=307c3669428c5362aab27c8a1260aa8f47c4e91d3891f48be0141738d8d053e1 +checksum=d4c6f9cf81f52d69230866796b82afbccdec3db7ae4fbd1b65ea750feed50037 post_install() { vlicense LICENSE.txt