From 9c7e203e902787436b4c017868d92b2ff7b1ef48 Mon Sep 17 00:00:00 2001 From: Jeff Epler Date: Tue, 17 Jan 2023 07:51:58 -0600 Subject: [PATCH] Fix after pylint update --- .pylintrc | 7 ------- jepler_udecimal/__init__.py | 20 ++++++++++---------- 2 files changed, 10 insertions(+), 17 deletions(-) diff --git a/.pylintrc b/.pylintrc index a4ddafa..203e349 100644 --- a/.pylintrc +++ b/.pylintrc @@ -391,10 +391,3 @@ max-statements=50 # Minimum number of public methods for a class (see R0903). min-public-methods=1 - - -[EXCEPTIONS] - -# Exceptions that will emit a warning when being caught. Defaults to -# "Exception" -overgeneral-exceptions=Exception diff --git a/jepler_udecimal/__init__.py b/jepler_udecimal/__init__.py index d322e9f..61841d4 100644 --- a/jepler_udecimal/__init__.py +++ b/jepler_udecimal/__init__.py @@ -1798,16 +1798,16 @@ class Decimal(object): else: return -self._round_down(prec) - _pick_rounding_function = dict( - ROUND_DOWN=_round_down, - ROUND_UP=_round_up, - ROUND_HALF_UP=_round_half_up, - ROUND_HALF_DOWN=_round_half_down, - ROUND_HALF_EVEN=_round_half_even, - ROUND_CEILING=_round_ceiling, - ROUND_FLOOR=_round_floor, - ROUND_05UP=_round_05up, - ) + _pick_rounding_function = { + ROUND_DOWN: _round_down, + ROUND_UP: _round_up, + ROUND_HALF_UP: _round_half_up, + ROUND_HALF_DOWN: _round_half_down, + ROUND_HALF_EVEN: _round_half_even, + ROUND_CEILING: _round_ceiling, + ROUND_FLOOR: _round_floor, + ROUND_05UP: _round_05up, + } def __round__(self, n=None): """Round self to the nearest integer, or to a given precision.