From e83c5f5fa0ef0118975f16f483f2831bbef2f3ef Mon Sep 17 00:00:00 2001 From: Matthew Munson Date: Fri, 27 Jul 2018 10:56:54 +0200 Subject: [PATCH] Removed a debugging print statement that had slipped under the radar --- CHANGES.md | 3 +++ MyCapytain/__init__.py | 2 +- MyCapytain/errors.py | 1 + MyCapytain/resources/texts/local/capitains/cts.py | 1 - 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 6bcb5162..aade3e7a 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,6 @@ +### 2018-07-27 2.0.9 @sonofmun + - Removed a random print statement that had been used for debugging empty references + ### 2018-06-25 2.0.8 @sonofmun - Corrected error on the empty references exception from 2.0.7 diff --git a/MyCapytain/__init__.py b/MyCapytain/__init__.py index 4a7ea86f..34485b98 100644 --- a/MyCapytain/__init__.py +++ b/MyCapytain/__init__.py @@ -9,4 +9,4 @@ """ -__version__ = "2.0.8" +__version__ = "2.0.9" diff --git a/MyCapytain/errors.py b/MyCapytain/errors.py index 93eebbb9..4a5b3e33 100644 --- a/MyCapytain/errors.py +++ b/MyCapytain/errors.py @@ -61,6 +61,7 @@ class UnknownCollection(KeyError, MyCapytainException): """ A collection is unknown to its ancestor """ + class EmptyReference(SyntaxWarning, MyCapytainException): """ Error generated when a duplicate is found in Reference """ diff --git a/MyCapytain/resources/texts/local/capitains/cts.py b/MyCapytain/resources/texts/local/capitains/cts.py index e37e7ef1..f870d077 100644 --- a/MyCapytain/resources/texts/local/capitains/cts.py +++ b/MyCapytain/resources/texts/local/capitains/cts.py @@ -251,7 +251,6 @@ def getValidReff(self, level=None, reference=None, _debug=False): empties = [n for n in passages if n.rstrip('.') != n or n == ''] if len(empties) > 0: message = '{} empty reference(s) at citation level {}'.format(len(empties), level) - print(empties) warnings.warn(message, EmptyReference) return passages