-
Notifications
You must be signed in to change notification settings - Fork 205
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
Not possible to avoid running on branches #415
Comments
Hey @goetzc 👋 Thank you for bringing this to our notice, and sorry for not getting to it sooner. We have a proof-of-concept Slack orb wholly written in Go that will potentially solve this pattern-matching issue and some others. Would you all be open to trying it and seeing if it solves your problem? We are looking for some early feedback. All you have to do is replace the orb version version: 2.1
orbs:
- slack: circleci/slack@4.12.5
+ slack: circleci/slack@dev:4463bcaee946c1e91829fdf6b3e0d1a7b6f12210 Please remember that {
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "$(cat /tmp/msg)"
}
}
]
} Thanks in advance, and let us know if it works for you! 🙇
|
@goetzc You explained two problems, the pattern not working and the exit 1. |
Version 4.14.0 is solving the issue with tag pattern. |
Orb version: 4.12.5
What happened:
I want to avoid sending the notification on any branch trigger, including the default
main
branch. Only want to send notifications on workflows triggered by tags. So I have setbranch_pattern
andtag_pattern
to different values without success.Or according to the README
slack-orb/README.md
Line 61 in 3e43e75
but it seems outdated as it's not working with:
Without any pattern (or using the
tag_pattern
) it send the notification. On any of thebranch_pattern
above, it fails with the following error:Which makes the whole job fail.
Expected behavior:
I expect it to avoid sending the notification on any branch (including the default branch), and exiting cleanly with code 0, so the whole workflow/job passes.
Additional Information:
I'm not sure if I'm missing something, as the normal job filters (
filters.tags.only
,filters.branches.only
orfilters.branches.ignore
) work normally. Is there some special pattern to avoid sending the notification on any branch?Thanks
The text was updated successfully, but these errors were encountered: