MovingBlocks / Terasology

Terasology - open source voxel world
http://terasology.org
Apache License 2.0
3.69k stars 1.34k forks source link

ci: update autoclose file version and fix github username #5097

Closed sfavello closed 1 year ago

sfavello commented 1 year ago

Contains

Fixes #5078. I updated the actions stale to the current version which is v8, changed the stale and closed message to be more friendlier similar to the recommended message in the proposal, and lastly I hopefully 🤞🏼 fixed the issue where the user's name was not coming through when the message appeared. I changed it to be more explicit in hopes that this may have been the issue 🤷🏼 I hope this is okay, but if any changes are needed, let me know. Happy to do so. 😄

sfavello commented 1 year ago

First of all, thank you very much for the contribution, it's highly appreciated 💚 I left some small language-wise nit-picky adjustments 🙂

I do have a bigger issue with the reference change as I'm not certain that ${{ github.event.pull_request.user.login }} will fix the problem. I would assume it to work (if at all) only for PRs, but we also want to have the info for issues when auto-closing them. As it's also the equivalent reference to get the user login for PRs instead of issues, I would expect it to run into the same issue as with ${{ github.event.issue.user.login }}.

Accordingly, I would ask you to revert that part of your change. We might want to look for existing issues in the action's repo / docs to see if somebody else faced a similar issue. We can also try running the action with debug logs - maybe that shows us the available event fields and their values. That could provide some insight into why it doesn't work right now 🤷‍♀️

Right now I'm also wondering why we only have configuration values on the message label and reason for issues - probably I only intended this action to auto-close issues, but not PRs... but why then the permissions on pull-requests? Are they maybe always required to run the action even if you don't want to apply it to pull requests?

Nice, thank you. I'm always happy to help. I went ahead and made the changes to the wording and reverted the github.event.pull_request.user.login change. I noticed in some of the forums and github issues there is always a space around the {{github.event.....}}. Unfortunately, I wasn't able to find anyone facing similar issues so far. A possible theory is having a space between the @ symbol and {{github.event...}} might solve this problem.