From a0cc269f90f5ac0e6f95e337009e26b144090650 Mon Sep 17 00:00:00 2001 From: Bert JW Regeer Date: Tue, 19 Jul 2016 15:57:26 -0600 Subject: re.split() requires non-empty match Change from a * to a +, so long as there is something to split on, it will split. Fixes this warning: FutureWarning: split() requires a non-empty pattern match. return _compile(pattern, flags).split(string, maxsplit) --- pyramid/scripts/proutes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyramid/scripts/proutes.py b/pyramid/scripts/proutes.py index 19d91cc72..f75810c06 100644 --- a/pyramid/scripts/proutes.py +++ b/pyramid/scripts/proutes.py @@ -296,7 +296,7 @@ class PRoutesCommand(object): items = config.items('proutes') for k, v in items: if 'format' == k: - cols = re.split(r'[,|\s|\n]*', v) + cols = re.split(r'[,|\s\n]+', v) self.column_format = [x.strip() for x in cols] except configparser.NoSectionError: -- cgit v1.2.3