-
-
Notifications
You must be signed in to change notification settings - Fork 227
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
feat(ci): use github actions instead of travis-ci #816
Conversation
cc @ashkulz |
@trygveaa I'd recommend requiring these checks to pass after merging the PR. |
Added two new commits which add python 3.8 and 3.9 to the test matrix. Please be sure to use any merge strategy except squashing (or squashing via interactive rebasing) so that the logical boundary of the commits remains. |
I'm also sitting on two commits:
but i think these would be best suited for adding in a separate PR |
This patch removes the configuration for Travis-CI, and adds configuration for Github Actions. Co-authored-by: Ashish Kulkarni <ashish@kulkarni.dev>
Could you add notification to #wee-slack-dev on freenode when the build fails, like the travis config has? |
Some initial cursory research doesn't show that this is possible. Github Actions currently supports email and web-based notifications for failed runs. I'll do a little more research tonight and/or think about how to best add support for this. Would this be considered a blocking feature? If this ends up requiring fairly heavy time involvement to support, I don't know that I'll have the time within the next 1-2 months to add support for it. |
Alright, thanks for having a look. Lets drop it. (irc notifications that is, not github actions). |
A user has created an action which interacts with IRC: https://github.com/rectalogic/notify-irc But the problem with using this comes about by the way GitHub Actions works; if a step fails then the workflow short circuits and reports a failure (via the email and/or web notification system, depending on your user settings). It might be possible to set some parameter to allow a step to fail but continue (I haven't had the need to look for this option yet, personally); I'll look into this tonight and get back to you by tomorrow morning. It may be helpful to note that if a workflow fails, the user that triggered the event(s) causing the workflow to run is the user that is notified. I don't believe you'd be notified for a run failure due to my PR, for example, but I would. |
Don't worry, let's drop it, you don't need to spend more time on it. I'm the only one in the IRC channel anyways, and I can use email notifications instead. I don't think I want an overly complex GitHub Actions config, the config is already pretty large.
Good to know, but for PRs from others I see the failure right above the merge button, so that's fine. |
Right, it definitely isn't obfuscated or hard to find failed runs :) You'll also see the green check mark (incdicating success) or red "x" (indicating failure) on the PR overview page, e.g. https://github.com/wee-slack/wee-slack/pulls |
Oops, accidentally hit the "close and comment" button. FWIW, I've contacted GitHub about the dual run caused by internal branches used to create PRs. If they get back to me with a better solution than the conditional check I have here on each step, I'll update the tree (or submit a new PR if this one is merged). |
I concluded the GitHub Support ticket. The conditional statement I have here on each step is the only way to accomplish the goal (to only run the workflow in response to only one of |
@sudoforge I'm not sure we need that condition; imagine that I'm the maintainer and make a PR just to get CI feedback -- it won't help as I think your condition will block the PR checks. Secondly, imagine that such a PR gets out-of-date due to other PRs getting merged -- having the checks being run again is good, as they'll be run again on the merge commit or rebased/squashed commit (which is not the same as the original commit). |
@ashkulz you're misunderstanding how GitHub Actions works, the Given the current configuration, the workflow will run:
Because the Without the conditional, internal branches used in a PR would run the workflow twice (on each update): once for the |
To put it another way... If you look at the checks that have been reported for this PR, you'll see the suffix If this PR's |
To give an actual example, see this PR I made for testing in another repository -- the workflow definition is similiar but there were no runs for the branch, I just saw the PR runs. You can verify this by going to the last commit as well. So the solution might be to just use |
That would make the workflow only run for push events to |
The current configuration is the only way to:
|
I believe that's a trade-off that would work for most repos, but yeah you're right -- if the requirements are as you've stated, then there's no other solution 🤷♂️ |
Yeah, if the maintainers collectively determine that they're fine with only running the workflow on commits to |
Thanks! |
I've also considered using black, so feel free to open a PR for that. |
No description provided.