Skip to content

Commit

Permalink
fix(pr-companion): reduce timestamp resolution (#7696)
Browse files Browse the repository at this point in the history
We don't need microsecond-resolution for the "comment last modified" value.
  • Loading branch information
bsmth authored Nov 29, 2022
1 parent 68d7396 commit a1f189e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion deployer/src/deployer/analyze_pr.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ def analyze_pr(build_directory: Path, config):
for comment in github_issue.get_comments():
if comment.user.login == "github-actions[bot]":
if hidden_comment_regex.search(comment.body):
combined_comment += f"\n\n*(this comment was updated {datetime.datetime.utcnow()})*"
now = datetime.datetime.utcnow().strftime("%Y-%m-%d %H:%M:%S")
combined_comment += f"\n\n*(comment last updated: {now})*"
comment.edit(body=combined_comment)
print(f"Updating existing comment ({comment})")
break
Expand Down

0 comments on commit a1f189e

Please sign in to comment.