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

Updates integTestRemote task to dynamically fetch common-utils version from build.gradle #3122

Conversation

DarshitChanpura
Copy link
Member

@DarshitChanpura DarshitChanpura commented Aug 8, 2023

Description

Fixes integTestRemote task to dynamically fetch common-utils version from build.gradle instead of hard-coding it in the shell script

Issues Resolved

Related to comment: #3018 (comment)

This changes addresses the issue permanently by modifying integTestRemote task to fetch the common-utils version dynamically from build.gradle, and prevent blocking RC builds in future due to such issue

Testing

Manual testing.

Check List

- [ ] New functionality includes testing
- [ ] New functionality has been documented

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@codecov
Copy link

codecov bot commented Aug 8, 2023

Codecov Report

Merging #3122 (79eb57a) into main (f299a5f) will decrease coverage by 0.04%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##               main    #3122      +/-   ##
============================================
- Coverage     62.43%   62.39%   -0.04%     
+ Complexity     3351     3349       -2     
============================================
  Files           254      254              
  Lines         19749    19749              
  Branches       3334     3334              
============================================
- Hits          12330    12323       -7     
- Misses         5788     5792       +4     
- Partials       1631     1634       +3     

see 7 files with indirect coverage changes

cwperks
cwperks previously approved these changes Aug 8, 2023
@DarshitChanpura
Copy link
Member Author

DarshitChanpura commented Aug 8, 2023

Backport CI task fails with: Error: Error: For security reasons, this action should only run on merged PRs.
I see it in couple of other PRs to main too. Seems like this task is configured to run only when PR is closed: https://github.com/VachaShah/backport/blob/3a8b1f98fd452ecaa4a262a55affb042c3e0ee69/.github/workflows/backport.yml#L3

Looks like this task started showing up in CI after this PR: #3063

…radle instead of hard-coding it in the shell script

Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
@DarshitChanpura
Copy link
Member Author

Backport CI task fails with: Error: Error: For security reasons, this action should only run on merged PRs. I see it in couple of other PRs to main too. Seems like this task is configured to run only when PR is closed: https://github.com/VachaShah/backport/blob/3a8b1f98fd452ecaa4a262a55affb042c3e0ee69/.github/workflows/backport.yml#L3

Looks like this task started showing up in CI after this PR: #3063

Seems like this task didn't run in the second-push.

Copy link
Member

@peternied peternied left a comment

Choose a reason for hiding this comment

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

I guess this is fine, you manually tested it and its unblocked? lets ship it

@DarshitChanpura DarshitChanpura merged commit 46989b5 into opensearch-project:main Aug 9, 2023
54 of 55 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/security/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/security/backport-2.x
# Create a new branch
git switch --create backport/backport-3122-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 46989b57d9cdf969be9473d1ca6bcb61c7923135
# Push it to GitHub
git push --set-upstream origin backport/backport-3122-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/security/backport-2.x

Then, create a pull request where the base branch is 2.x and the compare/head branch is backport/backport-3122-to-2.x.

DarshitChanpura added a commit to DarshitChanpura/security that referenced this pull request Aug 9, 2023
…n from build.gradle (opensearch-project#3122)

Fixes integTestRemote task to dynamically fetch common-utils version
from build.gradle instead of hard-coding it in the shell script

* Category : Refactoring

* Why these changes are required?
A temporary fix (opensearch-project#3018) was added to resolve CI failures in RC
generation caused due to out-of-date common-utils version being used in
the sanity test.

Related to comment:
opensearch-project#3018 (comment)

**This changes addresses the issue permanently by modifying
integTestRemote task to fetch the common-utils version dynamically from
build.gradle, and prevent blocking RC builds in future due to such
issue**

Signed-off-by: Darshit Chanpura <dchanp@amazon.com>
(cherry picked from commit 46989b5)
cwperks added a commit that referenced this pull request Aug 9, 2023
…on-utils version from build.gradle (#3122) (#3135)

(cherry picked from commit 46989b5)

Backports #3122 


### Check List
- [ ] New functionality includes testing
- [ ] New functionality has been documented
- [x] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and
signing off your commits, please check
[here](https://github.com/opensearch-project/OpenSearch/blob/main/CONTRIBUTING.md#developer-certificate-of-origin).

Co-authored-by: Craig Perkins <cwperx@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x backport to 2.x branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants