-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Infra - Fix API compatibility Github Action #4989
Conversation
This PR replaces #4974 |
cc @singhpk234 @ajantha-bhat @findepi I tested this exact configuration in my fork and it worked as seen here: https://github.com/kbendick/iceberg/runs/6780458052?check_suite_focus=true Please see the PR summary for my explanation of the issue. We can likely slowly add back in some of the cache layers, as I think the primary issue was the fact that it was checked out in a detached HEAD state (as shown by the log output of checkout action and as discussed in this issue. However for now I would like to merge in something that I have seen work for sure and then we can make this more efficient. |
I just checked in my fork and we can remove these flags I'm going to leave |
path: ~/.gradle/caches | ||
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} | ||
restore-keys: ${{ runner.os }}-gradle | ||
- run: ./gradlew :iceberg-api:revapi |
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.
We can potentially add back in the cache step, but for now I'd like to get this working in master
before fiddling with the individual arguments any further.
Thanks @kbendick for the change and comprehensive deep-dive, the above approach LGTM !! [question] : Have a small question, based on this article
Are we ok failing in the CI incase there is a merge conflict when merging base to the head ? Thoughts. |
Adding a specific But I agree, we should be ok as we need to resolve them anyhow before final merge. And I'd rather it give a false positive (a failure that is not an actual failure) than false negatives. If we do encounter a false positive, that will trigger somebody to go look and follow up. And like you said, we have to deal with this before merging anyway. |
@@ -35,18 +35,22 @@ concurrency: | |||
|
|||
jobs: | |||
revapi: | |||
runs-on: ubuntu-latest | |||
runs-on: ubuntu-20.04 |
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 is just to match our other actions.
This should be good to go now once tests pass @findepi @singhpk234 |
So if I understand the article correctly, we _might _ still need to use the specific branch for I tested in my fork without it, and it was fine. Additionally, the article states that in the worse case we'll get false positives. I'd rather that than false negatives as mentioned. Let's go with this simpler workflow for now as I've tested it extensively in my fork and if we get false positives - then we'll catch them and deal with it then. But thanks for the article link, it's very helpful. Same applies for false negatives which we should catch eventually as people run via the CLI which should always generate the proper result. |
Thanks, @kbendick! |
The API Binary compatibility task
revapi
, was previously skipping or occasionally passing when it shouldn't be (and when it was not passing for local gradle runs).The issues were two:
git describe
or the first line of the output ofgit tags
was not showing up. The action uses this tag to find the proper existing overrides and "old" version to pull from maven (currently iceberg-api:0.13.0)This removes the cache action, adds a step to output the
git describe
(so we can easily verify which tag is considered current, which corresponds to what's in.palantir/revapi.yml
), and then runs the revapi task pretty aggressively (with --rerun-tasks, --no-build-cache, and --no-daemon).We can try adding back in the
actions/cache
action as well as removing some of the aggressive flags for iceberg-api:revapi, but for now this is what I tested with in my fork and this will work. 🙂