From 0eeebe349d699c7dd5660eaa74758e16f00c64a2 Mon Sep 17 00:00:00 2001 From: Dpeta Date: Fri, 24 Jun 2022 05:30:06 +0200 Subject: [PATCH] recursion check --- dataobjs.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/dataobjs.py b/dataobjs.py index 1c5093f..a22ca81 100644 --- a/dataobjs.py +++ b/dataobjs.py @@ -167,7 +167,11 @@ class pesterQuirks(object): if len(excludes) >= 1: # SORT !!! excludes.sort(key=lambda exclude: exclude.start()) - + # Recursion check. + # Strings like http://:3: require this. + for n in range(0, len(excludes)-1): + if excludes[n].end() > excludes[n+1].start(): + excludes.pop(n) # Seperate parts to be quirked. sendparts = list() # Add string until start of exclude at index 0.