This is an automated email from the ASF dual-hosted git repository.

willbarrett pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git


The following commit(s) were added to refs/heads/master by this push:
     new d39bc14  test: optimize codecov config (#13329)
d39bc14 is described below

commit d39bc14a0b7808ce7cef20a0565c8d3fd9388ae9
Author: Jesse Yang <[email protected]>
AuthorDate: Thu Feb 25 03:22:34 2021 -1000

    test: optimize codecov config (#13329)
    
    * test: optimize codecov config to let GitHub checks always pass
    
    * Run tests on workflow changes, too
---
 .codecov.yml                                      | 5 +++++
 .github/workflows/bashlib.sh                      | 9 +++------
 .github/workflows/superset-frontend.yml           | 2 +-
 .github/workflows/superset-python-presto-hive.yml | 4 ++--
 .github/workflows/superset-python-unittest.yml    | 6 +++---
 scripts/ci_check_no_file_changes.sh               | 4 ++--
 6 files changed, 16 insertions(+), 14 deletions(-)

diff --git a/.codecov.yml b/.codecov.yml
index b093cfd..03a93cd 100644
--- a/.codecov.yml
+++ b/.codecov.yml
@@ -1,13 +1,18 @@
+codecov:
+    notify:
+        after_n_builds: 4
 ignore:
   - "superset/migrations/versions/*.py"
 coverage:
   status:
     project:
+      informational: true
       default:
         # Commits pushed to master should not make the overall
         # project coverage decrease:
         target: auto
         threshold: 0%
     patch:
+      informational: true
       default:
         threshold: 0%
diff --git a/.github/workflows/bashlib.sh b/.github/workflows/bashlib.sh
index b1d0edb..cfa8262 100644
--- a/.github/workflows/bashlib.sh
+++ b/.github/workflows/bashlib.sh
@@ -191,11 +191,6 @@ cypress-run-all() {
 
   cypress-run "*/**/*"
 
-  # Upload code coverage separately so each page can have separate flags
-  # -c will clean existing coverage reports, -F means add flags
-  # || true to prevent CI failure on codecov upload
-  codecov -cF "cypress" || true
-
   # After job is done, print out Flask log for debugging
   say "::group::Flask log for default run"
   cat "$flasklog"
@@ -211,8 +206,10 @@ cypress-run-all() {
 
   cypress-run "sqllab/*" "Backend persist"
 
+  # Upload code coverage separately so each page can have separate flags
+  # -c will clean existing coverage reports, -F means add flags
   # || true to prevent CI failure on codecov upload
-  codecov -cF "cypress" || true
+  codecov -c -F "cypress" || true
 
   say "::group::Flask log for backend persist"
   cat "$flasklog"
diff --git a/.github/workflows/superset-frontend.yml 
b/.github/workflows/superset-frontend.yml
index 2fe7113..a5d259b 100644
--- a/.github/workflows/superset-frontend.yml
+++ b/.github/workflows/superset-frontend.yml
@@ -45,4 +45,4 @@ jobs:
         if: steps.check.outcome == 'failure'
         working-directory: ./superset-frontend
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF javascript
+          bash <(curl -s https://codecov.io/bash) -c -F javascript
diff --git a/.github/workflows/superset-python-presto-hive.yml 
b/.github/workflows/superset-python-presto-hive.yml
index bfc6c5c..4eefa90 100644
--- a/.github/workflows/superset-python-presto-hive.yml
+++ b/.github/workflows/superset-python-presto-hive.yml
@@ -82,7 +82,7 @@ jobs:
       - name: Upload code coverage
         if: steps.check.outcome == 'failure'
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF python
+          bash <(curl -s https://codecov.io/bash) -c -F python -F presto
 
   test-postgres-hive:
     if: github.event.pull_request.draft == false
@@ -158,4 +158,4 @@ jobs:
       - name: Upload code coverage
         if: steps.check.outcome == 'failure'
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF python
+          bash <(curl -s https://codecov.io/bash) -c -F python -F hive
diff --git a/.github/workflows/superset-python-unittest.yml 
b/.github/workflows/superset-python-unittest.yml
index 91406c5..1f09350 100644
--- a/.github/workflows/superset-python-unittest.yml
+++ b/.github/workflows/superset-python-unittest.yml
@@ -70,7 +70,7 @@ jobs:
       - name: Upload code coverage
         if: steps.check.outcome == 'failure'
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF python
+          bash <(curl -s https://codecov.io/bash) -c -F python -F mysql
 
   test-postgres:
     if: github.event.pull_request.draft == false
@@ -134,7 +134,7 @@ jobs:
       - name: Upload code coverage
         if: steps.check.outcome == 'failure'
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF python
+          bash <(curl -s https://codecov.io/bash) -c -F python -F postgres
 
   test-sqlite:
     if: github.event.pull_request.draft == false
@@ -190,4 +190,4 @@ jobs:
       - name: Upload code coverage
         if: steps.check.outcome == 'failure'
         run: |
-          bash <(curl -s https://codecov.io/bash) -cF python
+          bash <(curl -s https://codecov.io/bash) -c -F python -F sqlite
diff --git a/scripts/ci_check_no_file_changes.sh 
b/scripts/ci_check_no_file_changes.sh
index 09e6bd1..80a89cc 100755
--- a/scripts/ci_check_no_file_changes.sh
+++ b/scripts/ci_check_no_file_changes.sh
@@ -34,10 +34,10 @@ REGEXES=()
 for CHECK in "$@"
 do
   if [[ ${CHECK} == "python" ]]; then
-    REGEX="(^tests\/|^superset\/|^setup\.py|^requirements\/.+\.txt)"
+    
REGEX="(^\.github\/workflows\/.*python|^tests\/|^superset\/|^setup\.py|^requirements\/.+\.txt)"
     echo "Searching for changes in python files"
   elif [[ ${CHECK} == "frontend" ]]; then
-    REGEX="(^superset-frontend\/)"
+    REGEX="(^\.github\/workflows\/.*(frontend|e2e)|^superset-frontend\/)"
     echo "Searching for changes in frontend files"
   else
     echo "Invalid check: \"${CHECK}\". Falling back to exiting with FAILURE 
code"

Reply via email to