Skip to content

Commit

Permalink
update default start / end times
Browse files Browse the repository at this point in the history
  • Loading branch information
seanshahkarami committed May 5, 2022
1 parent 3c3ac13 commit 6254ac7
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions rollup_plugin_counts.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
from utils import load_node_table, parse_time, get_rollup_range, time_windows, write_results_to_influxdb



def get_plugin_counts_for_window(nodes, start, end, convert_timestamps=False):
df = sage_data_client.query(start=start, end=end, filter={
"plugin": ".*"
Expand Down Expand Up @@ -47,7 +46,6 @@ def get_plugin_counts_for_window(nodes, start, end, convert_timestamps=False):
return records



def main():
INFLUXDB_URL = "https://influxdb.sagecontinuum.org"
INFLUXDB_ORG = "waggle"
Expand All @@ -58,8 +56,8 @@ def time_arg(s):
return parse_time(s, now=now)

parser = argparse.ArgumentParser()
parser.add_argument("--start", default="-2h", type=time_arg, help="relative start time")
parser.add_argument("--end", default="-1h", type=time_arg, help="relative end time")
parser.add_argument("--start", default="-1h", type=time_arg, help="relative start time")
parser.add_argument("--end", default="now", type=time_arg, help="relative end time")
parser.add_argument("--window", default="1h", type=pd.Timedelta, help="window duration to aggreagate over")
args = parser.parse_args()

Expand Down

0 comments on commit 6254ac7

Please sign in to comment.