From 6d1e4e5daf75476f388462fed52771f6aad81d91 Mon Sep 17 00:00:00 2001 From: Nicholas Bollweg Date: Fri, 1 Nov 2024 08:54:10 -0500 Subject: [PATCH] handle source.url as list --- conda_smithy/linter/hints.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/conda_smithy/linter/hints.py b/conda_smithy/linter/hints.py index a7b000ccb..d9f255c6b 100644 --- a/conda_smithy/linter/hints.py +++ b/conda_smithy/linter/hints.py @@ -39,9 +39,9 @@ def hint_sources_should_not_mention_pypi_io_but_pypi_org( See https://github.com/conda-forge/staged-recipes/pull/27946 """ for source_section in sources_section: - if (source_section.get("url", "") or "").startswith( - "https://pypi.io/" - ): + source = source_section.get("url", "") or "" + sources = [source] if isinstance(source, str) else source + if any(s.startswith("https://pypi.io/") for s in sources): hints.append( "PyPI default URL is now pypi.org, and not pypi.io." " You may want to update the default source url."