From 1785d5625b5dabe4904b1b77d4512fedf0faf15b Mon Sep 17 00:00:00 2001 From: Brian Koopman Date: Thu, 17 Oct 2024 16:34:54 -0400 Subject: [PATCH] Use new min_duration arg on seq.scan() from [1] [1] - https://github.com/simonsobs/sorunlib/pull/181 --- src/schedlib/policies/sat.py | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/schedlib/policies/sat.py b/src/schedlib/policies/sat.py index 114e577..02e3b3c 100644 --- a/src/schedlib/policies/sat.py +++ b/src/schedlib/policies/sat.py @@ -257,14 +257,13 @@ def cmb_scan(state, block): commands = [] commands.extend([ - f"scan_stop = {repr(block.t1)}", - f"if datetime.datetime.now(tz=UTC) < scan_stop - datetime.timedelta(minutes=10):", - " run.seq.scan(", - f" description='{block.name}',", - f" stop_time='{block.t1.isoformat()}',", - f" width={round(block.throw,3)}, az_drift=0,", - f" subtype='cmb', tag='{block.tag}',", - " )", + "run.seq.scan(", + f" description='{block.name}',", + f" stop_time='{block.t1.isoformat()}',", + f" width={round(block.throw,3)}, az_drift=0,", + f" subtype='cmb', tag='{block.tag}',", + f" min_duration=600,", + ")", ]) return state, (block.t1 - state.curr_time).total_seconds(), commands