From 773a3e83ad906b622e6417dd69bb44c7e80204ef Mon Sep 17 00:00:00 2001 From: "Joseph T. Lyons" Date: Thu, 4 Apr 2024 21:06:47 -0400 Subject: [PATCH] Don't require an issue number while in dev mode --- script/update_top_ranking_issues/main.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/script/update_top_ranking_issues/main.py b/script/update_top_ranking_issues/main.py index 6cbfd9a5d0..c51f3321e6 100644 --- a/script/update_top_ranking_issues/main.py +++ b/script/update_top_ranking_issues/main.py @@ -54,11 +54,14 @@ class IssueData: @app.command() def main( - issue_reference_number: int, + issue_reference_number: Optional[int] = None, github_token: Optional[str] = None, prod: bool = False, query_day_interval: Optional[int] = None, ) -> None: + if prod and not issue_reference_number: + raise ValueError("Issue reference number must be provided in prod mode") + start_time: datetime = datetime.now() start_date: datetime | None = None