From: Venky Shankar Date: Thu, 20 Aug 2020 09:42:29 +0000 (-0400) Subject: pybind / snap_schedule: remove 'SNAP_SCHED_TESTING' check X-Git-Tag: v16.1.0~562^2~5 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=471c9aeb512c3a9ec6bdcb8f610f1f43149d2c73;p=ceph.git pybind / snap_schedule: remove 'SNAP_SCHED_TESTING' check Next commit introduces a module option to allow minute granularity snapshots. Signed-off-by: Venky Shankar --- diff --git a/src/pybind/mgr/snap_schedule/fs/schedule.py b/src/pybind/mgr/snap_schedule/fs/schedule.py index 9b89f476e26c..d9246c1a3334 100644 --- a/src/pybind/mgr/snap_schedule/fs/schedule.py +++ b/src/pybind/mgr/snap_schedule/fs/schedule.py @@ -13,10 +13,6 @@ from typing import Tuple, Any log = logging.getLogger(__name__) - -TESTING = 'SNAP_SCHED_TESTING' in environ - - # Work around missing datetime.fromisoformat for < python3.7 SNAP_DB_TS_FORMAT = '%Y-%m-%dT%H:%M:%S' try: @@ -363,7 +359,7 @@ class Schedule(object): def repeat(self): mult = self.schedule[-1] period = int(self.schedule[0:-1]) - if TESTING and mult == 'M': + if mult == 'M': return period * 60 elif mult == 'h': return period * 60 * 60