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

Notify our slack on contributors' issue comments #11564

Merged
merged 3 commits into from
Dec 11, 2023

Conversation

vkWeb
Copy link
Member

@vkWeb vkWeb commented Nov 29, 2023

Summary

This adds a github action that will notify our slack #dev-community channel when any contributor comments on a issue.

ToDo --

  • Activate slack's webhook, already requested, need to be approved by one of our slack admins.
  • Add SLACK_WEBHOOK_URL as a GitHub secret.
  • Merge this PR and then test the action.

References

Closes #9521.

Reviewer guidance

I don't know how best to test this 🤷‍♂️


Testing checklist

  • Contributor has fully tested the PR manually
  • If there are any front-end changes, before/after screenshots are included
  • Critical user journeys are covered by Gherkin stories
  • Critical and brittle code paths are covered by unit tests

PR process

  • PR has the correct target branch and milestone
  • PR has 'needs review' or 'work-in-progress' label
  • If PR is ready for review, a reviewer has been added. (Don't use 'Assignees')
  • If this is an important user-facing change, PR or related issue has a 'changelog' label
  • If this includes an internal dependency change, a link to the diff is provided

Reviewer checklist

  • Automated test coverage is satisfactory
  • PR is fully functional
  • PR has been tested for accessibility regressions
  • External dependency files were updated if necessary (yarn and pip)
  • Documentation is updated
  • Contributor is in AUTHORS.md

@github-actions github-actions bot added DEV: dev-ops Continuous integration & deployment SIZE: small labels Nov 29, 2023
@MisRob MisRob requested review from rtibbles and MisRob November 29, 2023 14:09
run: |
curl -X POST -H 'Content-type: application/json' \
--data \
'{"text": "New comment on issue: '${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/issues/${{ github.event.issue.number }}' by '${GITHUB_ACTOR}'"}' \
Copy link
Member

Choose a reason for hiding this comment

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

Possible tweaks here:

  • Put the issue name instead of just 'issue'
  • Make a link out of the issue name
  • Update the link to include the reference to the specific comment so that clicking on it will open the issue at that specific comment
  • Could also make the github actor text link to the user profile of the github user.

Copy link
Member Author

Choose a reason for hiding this comment

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

I've included the issue title and linked it to the specific comment. I have not added github profile user link because that would be unnecessary.

@vkWeb vkWeb marked this pull request as ready for review December 9, 2023 11:25
@vkWeb
Copy link
Member Author

vkWeb commented Dec 9, 2023

@rtibbles marked this ready to merge. 🎉

Here's the link to the slack app that I added -- https://api.slack.com/apps/A067L07B9QW/incoming-webhooks. We need to add a webhook to that app, some instructions here on that -- https://api.slack.com/messaging/webhooks and we also need to add that webhook as a github secret.

@MisRob
Copy link
Member

MisRob commented Dec 11, 2023

Great, let's give it a try then? @rtibbles do you think you could help with setting Slack webhooks, please? We've tried earlier with @marcellamaki but neither of us has permissions.

@rtibbles
Copy link
Member

Was there a reason not to use the offiicial Slack github action here? https://github.com/slackapi/slack-github-action

@rtibbles
Copy link
Member

Readthedocs build seems to have stalled, merging anyway.

@rtibbles rtibbles merged commit 65fe4de into learningequality:develop Dec 11, 2023
33 checks passed
@vkWeb
Copy link
Member Author

vkWeb commented Dec 12, 2023

Was there a reason not to use the offiicial Slack github action here? https://github.com/slackapi/slack-github-action

No reason as such I guess, but I agree it would be better to use their official action, will fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DEV: dev-ops Continuous integration & deployment SIZE: small
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants