Skip to content

Commit

Permalink
post: Don't look at reviews with no comments
Browse files Browse the repository at this point in the history
This prevents post from merging messages with no comments such as
`clang-tidy found no files to check` with messages with comments.
  • Loading branch information
bwrsandman committed Jan 16, 2024
1 parent d71c19e commit 0b1bf4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion post/clang_tidy_review/clang_tidy_review/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,7 @@ def load_and_merge_reviews(review_files: List[pathlib.Path]) -> Optional[PRRevie
reviews = []
for file in review_files:
review = load_review(file)
if review is not None:
if review is not None and len(review.get("comments", [])) > 0:
reviews.append(review)

if not reviews:
Expand Down

0 comments on commit 0b1bf4c

Please sign in to comment.