Skip to content

Commit

Permalink
build: cancel previous github action runs (apache#11940)
Browse files Browse the repository at this point in the history
  • Loading branch information
ktmud authored Dec 8, 2020
1 parent 7e6f04f commit 8164aea
Show file tree
Hide file tree
Showing 9 changed files with 153 additions and 101 deletions.
36 changes: 20 additions & 16 deletions .github/workflows/superset-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,31 @@ name: Docs
on:
push:
paths:
- 'docs/**'
- "docs/**"
pull_request:
paths:
- 'docs/**'
- "docs/**"

jobs:
docs:
name: build
runs-on: ubuntu-18.04
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: npm install
working-directory: ./docs
run: |
npm install
- name: lint
working-directory: ./docs
run: |
npm run lint
- name: gatsby build
working-directory: ./docs
run: |
npm run build
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: npm install
working-directory: ./docs
run: |
npm install
- name: lint
working-directory: ./docs
run: |
npm run lint
- name: gatsby build
working-directory: ./docs
run: |
npm run build
116 changes: 60 additions & 56 deletions .github/workflows/superset-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
strategy:
fail-fast: true
matrix:
browser: ['chrome']
browser: ["chrome"]
env:
FLASK_ENV: development
ENABLE_REACT_CRUD_VIEWS: true
Expand All @@ -30,58 +30,62 @@ jobs:
ports:
- 16379:6379
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: '3.7'
- name: OS dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
apt-get-install
- name: Install python dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
pip-upgrade
pip install -r requirements/testing.txt
- name: Setup postgres
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
setup-postgres
- name: Import test data
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
testdata
- name: Install npm dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
npm-install
- name: Build javascript packages
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
build-instrumented-assets
- name: Install cypress
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
cypress-install
- name: Run Cypress
uses: apache-superset/cached-dependencies@b90713b
env:
CYPRESS_BROWSER: ${{ matrix.browser }}
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
with:
run: cypress-run-all
- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: failure()
with:
name: screenshots
path: ${{ github.workspace }}/superset-frontend/cypress-base/cypress/screenshots
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.7"
- name: OS dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
apt-get-install
- name: Install python dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
pip-upgrade
pip install -r requirements/testing.txt
- name: Setup postgres
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
setup-postgres
- name: Import test data
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
testdata
- name: Install npm dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
npm-install
- name: Build javascript packages
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
build-instrumented-assets
- name: Install cypress
uses: apache-superset/cached-dependencies@b90713b
with:
run: |
cypress-install
- name: Run Cypress
uses: apache-superset/cached-dependencies@b90713b
env:
CYPRESS_BROWSER: ${{ matrix.browser }}
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
with:
run: cypress-run-all
- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: failure()
with:
name: screenshots
path: ${{ github.workspace }}/superset-frontend/cypress-base/cypress/screenshots
42 changes: 23 additions & 19 deletions .github/workflows/superset-frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,26 @@ jobs:
build:
runs-on: ubuntu-18.04
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: npm-install
- name: lint
working-directory: ./superset-frontend
run: |
npm run lint
npm run prettier-check
- name: unit tests
working-directory: ./superset-frontend
run: |
npm run test -- --coverage
- name: Upload code coverage
working-directory: ./superset-frontend
run: |
bash <(curl -s https://codecov.io/bash) -cF javascript
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Install dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: npm-install
- name: lint
working-directory: ./superset-frontend
run: |
npm run lint
npm run prettier-check
- name: unit tests
working-directory: ./superset-frontend
run: |
npm run test -- --coverage
- name: Upload code coverage
working-directory: ./superset-frontend
run: |
bash <(curl -s https://codecov.io/bash) -cF javascript
12 changes: 12 additions & 0 deletions .github/workflows/superset-python-misc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ jobs:
matrix:
python-version: [3.7]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
Expand All @@ -33,6 +37,10 @@ jobs:
matrix:
python-version: [3.7]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
Expand All @@ -55,6 +63,10 @@ jobs:
matrix:
python-version: [3.7]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/superset-python-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ jobs:
ports:
- 16379:6379
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/superset-python-postgres.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ jobs:
ports:
- 16379:6379
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/superset-python-presto-hive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ jobs:
ports:
- 16379:6379
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
Expand Down Expand Up @@ -90,6 +94,10 @@ jobs:
ports:
- 16379:6379
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Create csv upload directory
run: sudo mkdir -p /tmp/.superset/uploads
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/superset-python-sqlite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ jobs:
ports:
- 16379:6379
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
Expand Down
28 changes: 18 additions & 10 deletions .github/workflows/superset-translations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,31 @@ jobs:
frontend-check:
runs-on: ubuntu-18.04
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: npm-install
- name: lint
working-directory: ./superset-frontend
run: |
npm run check-translation
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Install dependencies
uses: apache-superset/cached-dependencies@b90713b
with:
run: npm-install
- name: lint
working-directory: ./superset-frontend
run: |
npm run check-translation
babel-extract:
runs-on: ubuntu-18.04
strategy:
matrix:
python-version: [3.7]
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout code
uses: actions/checkout@v2
- name: Setup Python
Expand Down

0 comments on commit 8164aea

Please sign in to comment.