tools: fix check_review_status for new project-update

We have some new house rules for project-update which don't require a
timeframe that a change has to be opened for and only 2 roll call votes.

This patch updates the tooling to reflect it.

Change-Id: I7bde69d6abd6df004c60b80caf6669c24fef111a
This commit is contained in:
Mohammed Naser
2020-06-15 15:10:07 -04:00
parent cb69942dc9
commit 3f6d191614

View File

@@ -361,13 +361,10 @@ def get_one_status(change, delegates, tc_members):
elif topic in ('project-update', 'new-project'):
# https://governance.openstack.org/tc/reference/house-rules.html#other-project-team-updates
# At least 7 days old.
earliest = str(latest_created + creation_age_threshold)
if votes[-1] or code_reviews[-1]:
can_approve = 'dissenting votes'
elif age <= datetime.timedelta(7):
can_approve = 'too soon'
elif votes[1] < 2:
can_approve = 'not enough reviews'
else:
can_approve = 'CAN APPROVE'