Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix an issue where the bot doesn't ignore its own comments #73

Merged
merged 1 commit into from
May 19, 2020

Conversation

hross
Copy link
Contributor

@hross hross commented May 19, 2020

No description provided.

comments.filter(
comment =>
comment.user.type === 'User' &&
comment.user.login !== github.context.actor
Copy link

@rmacklin rmacklin Oct 2, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hross I added a scheduled workflow with the stale action and it seems that github.context.actor is myself, not the github actions bot. As a result, an issue that I had commented on after it was labeled stale ended up getting closed anyway. Here's what's in the logs for the action (incorrectly claiming that I am a bot):

Checking for comments on issue #15419 since 2020-09-22T00:06:03Z
Comments not made by rmacklin or another bot: 0

According to this post in the GitHub support community, it's expected behavior that the actor will be the user who set up the schedule:
https://github.community/t/who-will-be-the-github-actor-when-a-workflow-runs-on-a-schedule/17369

So if the intention of this check was to ignore bot comments, it seems like it's not working as intended.

Copy link

@rmacklin rmacklin Oct 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like others have run into the same issue: #21 (comment)

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've opened #192 where I propose we stop filtering out comments by github.context.actor when determining if there has been activity on the PR since it was marked as stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants