-
Notifications
You must be signed in to change notification settings - Fork 920
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(ci): detect breaking ci by comparing with base branch instead of main #3692
base: main
Are you sure you want to change the base?
Conversation
73bad92
to
3fc4bca
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3692 +/- ##
==========================================
+ Coverage 44.83% 45.54% +0.70%
==========================================
Files 265 281 +16
Lines 14620 16032 +1412
==========================================
+ Hits 6555 7301 +746
- Misses 7313 7889 +576
- Partials 752 842 +90 ☔ View full report in Codecov by Sentry. |
f661263
to
fbbf2c4
Compare
fbbf2c4
to
11f20bd
Compare
@MSevey could you please check the GitHub token access to ensure it has write privileges for pull requests? |
Why do you think you need updated permissions? The new action ran https://github.com/celestiaorg/celestia-node/actions/runs/10790001843 |
.github/workflows/labels.yml
Outdated
if: | | ||
(github.event.action == 'opened' || | ||
github.event.action == 'synchronize' || | ||
github.event.action == 'reopened' || | ||
github.event.action == 'edited' || | ||
github.event.action == 'labeled' || | ||
github.event.action == 'unlabeled') && | ||
github.actor != 'dependabot[bot]' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the majority of this condition is redundant since you are just checking that the action was trigger and the only action triggers are the ones you listed.
So you can just check for dependabot
if: | | |
(github.event.action == 'opened' || | |
github.event.action == 'synchronize' || | |
github.event.action == 'reopened' || | |
github.event.action == 'edited' || | |
github.event.action == 'labeled' || | |
github.event.action == 'unlabeled') && | |
github.actor != 'dependabot[bot]' | |
if: github.actor != 'dependabot[bot]' |
make detect-breaking | ||
|
||
- name: Add label if breaking changes detected | ||
- name: Check if 'kind:break!' label is already present |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This might be useful https://github.com/egmacke/action-check-label
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is a bit concerning action has no stars or forks. It feels safer to avoid using it
NUMBER: ${{ github.event.pull_request.number }} | ||
LABELS: kind:break! | ||
|
||
- name: Add 'kind:break!' label if breaking changes detected |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this might be useful https://github.com/marketplace/actions/actions-ecosystem-add-labels
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tried to use it, but it didn't work for some reason. Perhaps, you might want to contribute to this PR?
0ac17cf
to
0238dac
Compare
Error in the action file preventing it from running https://github.com/celestiaorg/celestia-node/actions/runs/10813060223 You should install |
Refactor the action to:
TODO: tokens need permissions to write to pull requests to allow this action to set up the label