Switch election timing to Wednesday

Tuesday was selected because it was early in the week and was "safe"
for APAC and US timezones.   Releases actually happen on Wednesdays
so for something more like consistency lets do make elections also
happen on Wednesdays

Change-Id: If66602b12eb77b17904427149ab81ce7a21d9492
This commit is contained in:
Tony Breeds 2022-10-18 11:03:42 -05:00 committed by Ian Y. Choi
parent e9aba065ff
commit 4ef299381b
1 changed files with 4 additions and 4 deletions

View File

@ -54,9 +54,9 @@ def valid_date(opt):
return d.replace(tzinfo=pytz.UTC)
def first_tuesday(date):
def find_previous_wednesday(date):
# The are smarter ways to do this
while date.weekday() != 1:
while date.weekday() != 2:
date -= datetime.timedelta(days=1)
return date
@ -164,8 +164,8 @@ def main():
args.date.date()))
end = args.date - offset
print('Latest possible completion is at: %s' % (end.date()))
end = first_tuesday(end)
print('Moving back to Tuesday: %s' % (end.date()))
end = find_previous_wednesday(end)
print('Moving back to Wednesday: %s' % (end.date()))
end = end.replace(hour=23, minute=45)
events = []