From 20981f10b94da5e98700c5e2169a61fc78d14475 Mon Sep 17 00:00:00 2001 From: jan Date: Sun, 16 Feb 2020 18:17:28 -0800 Subject: [PATCH] Fix error name InvalidDataError -> PatternError --- masque/repetition.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/masque/repetition.py b/masque/repetition.py index bf03d95..5ed652e 100644 --- a/masque/repetition.py +++ b/masque/repetition.py @@ -78,7 +78,7 @@ class GridRepetition: :param b_count: Number of elements in the b_vector direction. Should be omitted if b_vector was omitted. :param locked: Whether the subpattern is locked after initialization. - :raises: InvalidDataError if b_* inputs conflict with each other + :raises: PatternError if b_* inputs conflict with each other or a_count < 1. """ if b_vector is None: @@ -88,11 +88,11 @@ class GridRepetition: b_vector = numpy.array([0.0, 0.0]) if a_count < 1: - raise InvalidDataError('Repetition has too-small a_count: ' - '{}'.format(a_count)) + raise PatternError('Repetition has too-small a_count: ' + '{}'.format(a_count)) if b_count < 1: - raise InvalidDataError('Repetition has too-small b_count: ' - '{}'.format(b_count)) + raise PatternError('Repetition has too-small b_count: ' + '{}'.format(b_count)) self.unlock() self.a_vector = a_vector self.b_vector = b_vector