Skip to content

Commit b0799b5

Browse files
rusackasclaude
andcommitted
fix(ci): match the latest earlier VOTE by subject in SIP steward
Co-Authored-By: Evan Rusackas <evan@preset.io> Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
1 parent 794829a commit b0799b5

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

‎scripts/sip_steward.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -735,7 +735,7 @@ def _find_vote(
735735
if thread_id in linked:
736736
return vote
737737
subject = classify_subject(result.subject)[2:]
738-
for vote in vote_by_thread.values():
738+
for vote in reversed(vote_by_thread.values()):
739739
if classify_subject(vote[0].subject)[2:] == subject:
740740
return vote
741741
return None

‎tests/unit_tests/scripts/sip_steward_test.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,8 @@ def test_failed_result_blocks_a_passed_result() -> None:
361361
def test_non_sip_thread_is_ignored() -> None:
362362
issues = {1: make_issue(1, SIP_TITLE)}
363363
steward = make_steward(FakeModel("passed"))
364-
other = Email("o" * 32, "[VOTE] Release 5.0 candidate", 0, "")
364+
body = "Includes https://github.com/apache/superset/issues/1"
365+
other = Email("o" * 32, "[VOTE] Release 5.0 candidate", 0, body)
365366
assert steward._collect_evidence(issues, [other]) == {}
366367

367368

0 commit comments

Comments
 (0)