You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by ch...@apache.org on 2022/09/07 12:03:14 UTC
[incubator-kyuubi] branch master updated: [KYUUBI #3422] [CI] Run install before checking style
This is an automated email from the ASF dual-hosted git repository.
chengpan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-kyuubi.git
The following commit(s) were added to refs/heads/master by this push:
new 6570d4aeb [KYUUBI #3422] [CI] Run install before checking style
6570d4aeb is described below
commit 6570d4aebb57ac73548e9e13e85fc39cc4e5f1e3
Author: Fu Chen <cf...@gmail.com>
AuthorDate: Wed Sep 7 20:03:04 2022 +0800
[KYUUBI #3422] [CI] Run install before checking style
### _Why are the changes needed?_
To avoid unexpected errors on bumping version and adding new modules.
do some tests based on this PR.
- https://github.com/cfmcgrady/incubator-kyuubi/pull/22
- https://github.com/cfmcgrady/incubator-kyuubi/pull/23
- https://github.com/cfmcgrady/incubator-kyuubi/pull/24
- https://github.com/cfmcgrady/incubator-kyuubi/pull/25
### _How was this patch tested?_
Pass CI.
Closes #3422 from cfmcgrady/style-ci.
Closes #3422
f79e2d43 [Fu Chen] remove out-of-date comment
f2a87976 [Fu Chen] address comment
b7a4e487 [Fu Chen] add comment
df3c543e [Fu Chen] connector-hive
7962663b [Fu Chen] kudu
2b55eb1c [Fu Chen] spark-3.3
6120f3a2 [Fu Chen] install spark-3.3
0b13bc60 [Fu Chen] update
bb71fb24 [Fu Chen] condition
7b00c6cd [Fu Chen] continue-on-error
c978a946 [Fu Chen] install submodule
f20228e0 [Fu Chen] [CI] Run install before checking style
Authored-by: Fu Chen <cf...@gmail.com>
Signed-off-by: Cheng Pan <ch...@apache.org>
---
.github/workflows/style.yml | 32 ++++++++++++++++++++++++--------
1 file changed, 24 insertions(+), 8 deletions(-)
diff --git a/.github/workflows/style.yml b/.github/workflows/style.yml
index fa872ed7e..48f112b36 100644
--- a/.github/workflows/style.yml
+++ b/.github/workflows/style.yml
@@ -27,15 +27,15 @@ concurrency:
group: linter-${{ github.ref }}
cancel-in-progress: true
-# no install runs before style check because it is expensive, we can skip build if style fails
-# Well, sometimes when we introduce a new module, it may 'fail' the style check for missing
-# dependency we just create for other module to inherit.
-# We can ignore this failure and merge the PR, if we see the style check pass on the new module
-# or via a local quick verification.
jobs:
linter:
name: Style check
runs-on: ubuntu-22.04
+ strategy:
+ matrix:
+ profiles:
+ - '-Pflink-provided,hive-provided,spark-provided,spark-block-cleaner,spark-3.3,spark-3.2,spark-3.1,tpcds'
+
steps:
- uses: actions/checkout@v2
- name: Setup JDK 8
@@ -45,10 +45,26 @@ jobs:
java-version: 8
cache: 'maven'
check-latest: false
+ - name: Check kyuubi modules avaliable
+ id: modules-check
+ run: build/mvn dependency:resolve -DincludeGroupIds="org.apache.kyuubi" -DincludeScope="compile" -DexcludeTransitive=true ${{ matrix.profiles }}
+ continue-on-error: true
+
+ - name: Install
+ # When a continue-on-error step fails, the outcome is failure, but the final conclusion is success.
+ # for more details, please visit: https://github.com/actions/toolkit/issues/399#issuecomment-666147717
+ if: steps.modules-check.conclusion == 'success' && steps.modules-check.outcome == 'failure'
+ run: |
+ MVN_OPT="-DskipTests -Dorg.slf4j.simpleLogger.defaultLogLevel=warn -Dmaven.javadoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -Dspotless.check.skip"
+ build/mvn clean install ${MVN_OPT} -Pflink-provided,hive-provided,spark-provided,spark-block-cleaner,spark-3.2,tpcds
+ build/mvn clean install ${MVN_OPT} -pl extensions/spark/kyuubi-extension-spark-3-1 -Pspark-3.1
+ build/mvn clean install ${MVN_OPT} -pl extensions/spark/kyuubi-extension-spark-3-3,extensions/spark/kyuubi-spark-connector-kudu,extensions/spark/kyuubi-spark-connector-hive -Pspark-3.3
+
- name: Scalastyle with maven
- run: build/mvn scalastyle:check -Pflink-provided,hive-provided,spark-provided,spark-block-cleaner,spark-3.3,spark-3.2,spark-3.1,tpcds
+ id: scalastyle-check
+ run: build/mvn scalastyle:check ${{ matrix.profiles }}
- name: Print scalastyle error report
- if: failure()
+ if: failure() && steps.scalastyle-check.outcome != 'success'
run: >-
for log in `find * -name "scalastyle-output.xml"`;
do
@@ -57,7 +73,7 @@ jobs:
fi
done
- name: JavaStyle with maven
- run: build/mvn spotless:check -Pflink-provided,hive-provided,spark-provided,spark-block-cleaner,spark-3.3,spark-3.2,spark-3.1,tpcds
+ run: build/mvn spotless:check ${{ matrix.profiles }}
- name: setup npm
uses: actions/setup-node@v3
with: