Skip to content

Commit 422ce14

Browse files
authored
Merge branch 'master' into master
2 parents 49e10e1 + 19f64ec commit 422ce14

File tree

14 files changed

+119
-245
lines changed

14 files changed

+119
-245
lines changed

.github/OWNERS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
approvers:
22
- hbelmiro
33
- mprahl
4+
- nsingla
45
reviewers:
56
- droctothorpe
67
- gmfrasca
8+
- nsingla

.github/actions/check-artifact-exists/action.yml

Lines changed: 0 additions & 38 deletions
This file was deleted.

.github/actions/check-artifact-exists/check_artifact.py

Lines changed: 0 additions & 153 deletions
This file was deleted.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
kubernetes==30.1.0
2-
urllib3==2.5.0
2+
urllib3==2.6.3

.github/workflows/ci-checks.yml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,28 +9,24 @@ jobs:
99
check_ci_status:
1010
runs-on: ubuntu-latest
1111
permissions:
12-
checks: read
13-
pull-requests: write
12+
checks: read
1413
steps:
1514
- name: Check out the repository
1615
uses: actions/checkout@v5
1716

1817
- name: Check for 'needs-ok-to-test' and 'ok-to-test' labels
1918
id: label_check
20-
run: |
21-
LABELS=$(gh pr view ${{ github.event.pull_request.number }} --json labels --jq '.labels[].name')
22-
if echo "$LABELS" | grep -q 'needs-ok-to-test'; then
19+
run: |
20+
if [[ "${{ contains(github.event.pull_request.labels.*.name, 'needs-ok-to-test') }}" == "true" ]]; then
2321
echo "Label 'needs-ok-to-test' found. Skipping the workflow."
2422
exit 0
25-
fi
26-
if echo "$LABELS" | grep -q 'ok-to-test'; then
23+
fi
24+
if [[ "${{ contains(github.event.pull_request.labels.*.name, 'ok-to-test') }}" == "true" ]]; then
2725
echo "Label 'ok-to-test' found. Continuing the workflow."
2826
else
2927
echo "Label 'ok-to-test' not found. Skipping the workflow."
3028
exit 0
3129
fi
32-
env:
33-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3430
3531
- name: Check if all CI checks passed
3632
uses: wechuli/allcheckspassed@0b68b3b7d92e595bcbdea0c860d05605720cf479

.github/workflows/gh-workflow-approve.yml

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -23,25 +23,25 @@ jobs:
2323
steps:
2424
- name: Check if author is a Kubeflow GitHub member
2525
id: membership-check
26-
uses: actions/github-script@v8
27-
with:
28-
script: |
29-
const username = context.payload.pull_request.user.login;
30-
const org = context.repo.owner;
31-
try {
32-
const res = await github.rest.orgs.checkMembershipForUser({
33-
org,
34-
username
35-
});
36-
core.setOutput("is_member", true);
37-
} catch (error) {
38-
if (error.status === 404) {
39-
// User is not a member
40-
core.setOutput("is_member", false);
41-
} else {
42-
throw error;
43-
}
44-
}
26+
env:
27+
AUTHOR_ASSOCIATION: ${{ github.event.pull_request.author_association }}
28+
PR_AUTHOR: ${{ github.event.pull_request.user.login }}
29+
PR_NUMBER: ${{ github.event.pull_request.number }}
30+
run: |
31+
echo "::group::PR Information"
32+
echo "PR Number: #$PR_NUMBER"
33+
echo "PR Author: $PR_AUTHOR"
34+
echo "Author Association: $AUTHOR_ASSOCIATION"
35+
echo "::endgroup::"
36+
37+
# MEMBER = org member, OWNER = org owner, COLLABORATOR = invited collaborator
38+
if [[ "$AUTHOR_ASSOCIATION" == "MEMBER" || "$AUTHOR_ASSOCIATION" == "OWNER" || "$AUTHOR_ASSOCIATION" == "COLLABORATOR" ]]; then
39+
echo "::notice::Author '$PR_AUTHOR' is a trusted contributor (association: $AUTHOR_ASSOCIATION). Auto-approving workflow runs."
40+
echo "is_member=true" >> $GITHUB_OUTPUT
41+
else
42+
echo "::notice::Author '$PR_AUTHOR' is not a trusted contributor (association: $AUTHOR_ASSOCIATION). Checking for 'ok-to-test' label."
43+
echo "is_member=false" >> $GITHUB_OUTPUT
44+
fi
4545
4646
- name: Approve Pending Workflow Runs
4747
if: steps.membership-check.outputs.is_member == 'true' || contains(github.event.pull_request.labels.*.name, 'ok-to-test')

.github/workflows/image-builds-with-cache.yml

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -82,17 +82,19 @@ jobs:
8282
echo "registry=${{ env.REGISTRY }}"
8383
} >> "$GITHUB_OUTPUT"
8484
85-
# Check if the image tarball already exists or not, if yes, then skip building the image
86-
- name: Check artifact exists
87-
uses: ./.github/actions/check-artifact-exists
85+
# Check if the image was already built for this SHA using cache
86+
- name: Check if already built
87+
id: cache-check
8888
if: ${{ github.ref_name != github.event.repository.default_branch }}
89+
uses: actions/cache@v5
8990
with:
90-
artifact_name: ${{ env.ARTIFACT_NAME }}
91-
id: artifact-check
91+
path: .build-marker-${{ matrix.image }}
92+
key: image-built-${{ matrix.image }}-${{ github.sha }}
93+
lookup-only: true
9294

9395
- name: Set up Docker Buildx
9496
uses: docker/setup-buildx-action@v3
95-
if: ${{ steps.artifact-check.outputs.exists == 'false' || github.ref_name == github.event.repository.default_branch }}
97+
if: ${{ steps.cache-check.outputs.cache-hit != 'true' || github.ref_name == github.event.repository.default_branch }}
9698
id: setup-buildx
9799

98100
- name: Build and save Docker image
@@ -125,4 +127,15 @@ jobs:
125127
path: ${{ env.ARTIFACTS_PATH }}/${{ env.ARTIFACT_NAME }}.tar
126128
retention-days: 1
127129
# Continue the workflow even if the upload failed, because upload can fail if other jobs were able to upload artifact first before the current one
128-
continue-on-error: true
130+
continue-on-error: true
131+
132+
- name: Create build marker
133+
if: ${{ steps.save-image.outcome == 'success' || steps.rebuild.outcome == 'success' }}
134+
run: echo "built" > .build-marker-${{ matrix.image }}
135+
136+
- name: Save build marker to cache
137+
if: ${{ steps.save-image.outcome == 'success' || steps.rebuild.outcome == 'success' }}
138+
uses: actions/cache/save@v5
139+
with:
140+
path: .build-marker-${{ matrix.image }}
141+
key: image-built-${{ matrix.image }}-${{ github.sha }}

backend/metadata_writer/requirements.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,18 @@ grpcio==1.74.0
2525
idna==3.10
2626
# via requests
2727
kubernetes==31.0.0
28-
# via -r requirements.in
28+
# via -r metadata_writer/requirements.in
2929
lru-dict==1.3.0
30-
# via -r requirements.in
30+
# via -r metadata_writer/requirements.in
3131
ml-metadata==1.17.0
32-
# via -r requirements.in
32+
# via -r metadata_writer/requirements.in
3333
oauthlib==3.3.1
3434
# via
3535
# kubernetes
3636
# requests-oauthlib
3737
protobuf==4.25.8
3838
# via ml-metadata
39-
pyasn1==0.6.1
39+
pyasn1==0.6.2
4040
# via
4141
# pyasn1-modules
4242
# rsa
@@ -46,7 +46,7 @@ python-dateutil==2.9.0.post0
4646
# via kubernetes
4747
pyyaml==6.0.2
4848
# via
49-
# -r requirements.in
49+
# -r metadata_writer/requirements.in
5050
# kubernetes
5151
requests==2.32.5
5252
# via
@@ -61,7 +61,7 @@ six==1.17.0
6161
# kubernetes
6262
# ml-metadata
6363
# python-dateutil
64-
urllib3==2.6.0
64+
urllib3==2.6.3
6565
# via
6666
# kubernetes
6767
# requests

backend/requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ googleapis-common-protos==1.70.0
4848
idna==3.10
4949
# via requests
5050
kfp==2.14.3
51-
# via -r -
51+
# via -r requirements.in
5252
kfp-pipeline-spec==2.14.0
5353
# via kfp
5454
kfp-server-api==2.14.3
@@ -102,7 +102,7 @@ six==1.17.0
102102
# python-dateutil
103103
tabulate==0.9.0
104104
# via kfp
105-
urllib3==2.5.0
105+
urllib3==2.6.3
106106
# via
107107
# kfp
108108
# kfp-server-api

0 commit comments

Comments
 (0)