Skip to content

Commit ec4f770

Browse files
alonre24DvirDukhan
andauthored
remove tj-actions [0.7] (#609)
* CP docs comparison * CP avoid using upload-artifacts v3 --------- Co-authored-by: DvirDukhan <dvir@redis.com>
1 parent 43320f5 commit ec4f770

File tree

4 files changed

+15
-93
lines changed

4 files changed

+15
-93
lines changed

.github/workflows/event-merge-to-queue.yml

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,12 @@ on:
88
types: [checks_requested]
99

1010
jobs:
11-
check-if-docs-only:
12-
uses: ./.github/workflows/task-check-docs.yml
1311

1412
jammy:
15-
needs: [check-if-docs-only]
16-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
1713
uses: ./.github/workflows/task-unit-test.yml
1814
with:
1915
container: ubuntu:jammy
2016
focal:
21-
needs: [check-if-docs-only]
22-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
2317
uses: ./.github/workflows/task-unit-test.yml
2418
with:
2519
container: ubuntu:focal
@@ -30,8 +24,6 @@ jobs:
3024
# with:
3125
# container: ubuntu:bionic
3226
bullseye:
33-
needs: [check-if-docs-only]
34-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
3527
uses: ./.github/workflows/task-unit-test.yml
3628
with:
3729
container: debian:bullseye
@@ -46,40 +38,27 @@ jobs:
4638
# with:
4739
# container: centos:7
4840
mariner2:
49-
needs: [check-if-docs-only]
50-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
5141
uses: ./.github/workflows/mariner2.yml
5242
rocky8:
53-
needs: [check-if-docs-only]
54-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
5543
uses: ./.github/workflows/task-unit-test.yml
5644
with:
5745
container: rockylinux:8
5846
rocky9:
59-
needs: [check-if-docs-only]
60-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
6147
uses: ./.github/workflows/task-unit-test.yml
6248
with:
6349
container: rockylinux:9
6450
macos:
65-
needs: [check-if-docs-only]
66-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
6751
uses: ./.github/workflows/macos.yml
6852
arm:
69-
needs: [check-if-docs-only]
70-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
7153
uses: ./.github/workflows/arm.yml
7254
secrets: inherit
7355

7456
coverage:
75-
needs: [check-if-docs-only]
76-
if: ${{ needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
7757
uses: ./.github/workflows/coverage.yml
7858
secrets: inherit
7959

8060
pr-validation:
8161
needs:
82-
- check-if-docs-only
8362
- jammy
8463
- focal
8564
# - bionic

.github/workflows/event-pull_request.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,10 @@ on:
55
types: [opened, synchronize, reopened, ready_for_review] # Defaults + ready_for_review
66

77
jobs:
8-
check-if-docs-only:
9-
uses: ./.github/workflows/task-check-docs.yml
108

119
basic-tests:
1210
name: basic tests
1311
runs-on: ubuntu-latest
14-
needs: check-if-docs-only
15-
if: needs.check-if-docs-only.outputs.only-docs-changed == 'false'
1612
concurrency:
1713
group: ${{ github.workflow }}-${{ github.ref }}
1814
cancel-in-progress: true
@@ -35,14 +31,13 @@ jobs:
3531
run: make flow_test
3632

3733
coverage:
38-
needs: [basic-tests, check-if-docs-only]
39-
if: ${{ !github.event.pull_request.draft && needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
34+
needs: [basic-tests]
35+
if: ${{ !github.event.pull_request.draft}}
4036
uses: ./.github/workflows/coverage.yml
4137
secrets: inherit
4238

4339
codeql-analysis:
44-
needs: [check-if-docs-only]
45-
if: ${{ !github.event.pull_request.draft && needs.check-if-docs-only.outputs.only-docs-changed == 'false' }}
40+
if: ${{ !github.event.pull_request.draft}}
4641
uses: ./.github/workflows/codeql-analysis.yml
4742
secrets: inherit
4843

@@ -58,7 +53,6 @@ jobs:
5853

5954
pr-validation:
6055
needs:
61-
- check-if-docs-only
6256
- basic-tests
6357
- coverage
6458
- codeql-analysis

.github/workflows/task-check-docs.yml

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

.github/workflows/task-unit-test.yml

Lines changed: 12 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020

2121
jobs:
2222
test:
23-
name: Test ${{ inputs.container || inputs.env }}
23+
name: Test ${{ inputs.container && format('{0} (on {1})', inputs.container, inputs.env) || inputs.env }}
2424
runs-on: ${{ inputs.env }}
2525
container: ${{ inputs.container || null }}
2626
defaults:
@@ -31,51 +31,29 @@ jobs:
3131
if: ${{ inputs.pre-checkout-script }}
3232
shell: sh -l -eo pipefail {0}
3333
run: ${{ inputs.pre-checkout-script }}
34-
- name: Check for node20 support
35-
id: node20 # TODO: Remove this when node20 is supported on all platforms, or when we drop support for theses platforms
36-
run: |
37-
for os in amazonlinux:2 ubuntu:bionic centos:7 ubuntu:xenial; do
38-
if [ "${{ inputs.container }}" = "$os" ]; then
39-
# https://github.com/actions/checkout/issues/1809
40-
# https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
41-
echo "ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true" >> $GITHUB_ENV
42-
echo "supported=false" >> $GITHUB_OUTPUT
43-
exit 0
44-
fi
45-
done
46-
echo "supported=true" >> $GITHUB_OUTPUT
4734
- name: checkout
48-
if: steps.node20.outputs.supported == 'true'
4935
uses: actions/checkout@v4
5036
with:
5137
ref: ${{ github.event.number && format('refs/pull/{0}/merge', github.event.number) || github.head_ref }}
52-
- name: checkout (fallback)
53-
if: steps.node20.outputs.supported == 'false'
54-
uses: actions/checkout@v3
55-
with:
56-
ref: ${{ github.event.number && format('refs/pull/{0}/merge', github.event.number) || github.head_ref }}
5738
- name: install dependencies
5839
run: .install/install_script.sh ${{ !inputs.container && 'sudo' || '' }}
40+
- name: Set Artifact Name
41+
# Artifact names have to be unique, so we base them on the environment.
42+
# We also remove invalid characters from the name.
43+
id: artifact-name
44+
run: | # Invalid characters include: Double quote ", Colon :, Less than <, Greater than >, Vertical bar |, Asterisk *, Question mark ?
45+
NAME="${{ inputs.container && format('{0} (on {1})', inputs.container, inputs.env) || inputs.env }} ${{ runner.arch }}"
46+
NAME="$(echo $NAME | sed -e 's/[":\/\\<>\|*?]/_/g')" # Replace invalid characters with underscores
47+
echo "name=$NAME" >> $GITHUB_OUTPUT
48+
5949
- name: unit tests
6050
run: make unit_test
6151
- name: valgrind
6252
if: ${{ inputs.run-valgrind }}
6353
run: make valgrind
64-
- name: Set Artifact Names
65-
# Artifact names have to be unique, so we base them on the environment.
66-
# We also remove invalid characters from the name.
67-
id: artifact-names
68-
run: | # Invalid characters include: Double quote ", Colon :, Less than <, Greater than >, Vertical bar |, Asterisk *, Question mark ?
69-
echo "name=$(echo "${{ inputs.container || inputs.env }} ${{ runner.arch }}" | sed -e 's/[":\/\\<>\|*?]/_/g')" >> $GITHUB_OUTPUT
7054
- name: Archive valgrind tests reports
71-
if: ${{ inputs.run-valgrind && failure() && steps.node20.outputs.supported == 'true' }}
55+
if: ${{ inputs.run-valgrind && failure() }}
7256
uses: actions/upload-artifact@v4
7357
with:
74-
name: valgrind tests reports ${{ steps.artifact-names.outputs.name }}
75-
path: bin/Linux-x86_64-debug/unit_tests/Testing/Temporary/
76-
- name: Archive valgrind tests reports (fallback)
77-
if: ${{ inputs.run-valgrind && failure() && steps.node20.outputs.supported == 'false' }}
78-
uses: actions/upload-artifact@v3
79-
with:
80-
name: valgrind tests reports ${{ steps.artifact-names.outputs.name }}
58+
name: valgrind tests reports on ${{ steps.artifact-name.outputs.name }}
8159
path: bin/Linux-x86_64-debug/unit_tests/Testing/Temporary/

0 commit comments

Comments
 (0)