From 8cfc614714f8f04e2ea9824c6ade1971731e138d Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Tue, 18 Jul 2023 08:55:27 -0500 Subject: [PATCH] Revert --- conda_build/utils.py | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/conda_build/utils.py b/conda_build/utils.py index 9297613bfc..60f3cec3d3 100644 --- a/conda_build/utils.py +++ b/conda_build/utils.py @@ -1268,19 +1268,13 @@ def islist(arg, uniform=False, include_dict=True): :return: Whether `arg` is a `list` :rtype: bool """ - if isinstance(arg, str): - # strs are not sequences - return False - elif not isinstance(arg, Iterable): - # non-iterables are not sequences + if isinstance(arg, str) or not isinstance(arg, Iterable): + # str and non-iterables are not lists return False elif not include_dict and isinstance(arg, dict): - # do not treat dict as a sequence + # do not treat dict as a list return False - - # found a valid sequence! - - if not uniform: + elif not uniform: # short circuit for non-uniformity return True