From 7b0488dc7fc9cecaf37802cad28ab91586213ea6 Mon Sep 17 00:00:00 2001 From: Rubicon Rowe Date: Mon, 27 Feb 2023 22:05:52 +0800 Subject: [PATCH 1/5] Added type checking CI flow --- .github/workflows/typechecking.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/typechecking.yml diff --git a/.github/workflows/typechecking.yml b/.github/workflows/typechecking.yml new file mode 100644 index 00000000..29da9f6f --- /dev/null +++ b/.github/workflows/typechecking.yml @@ -0,0 +1,26 @@ +name: "Type Checking" + +on: [push, pull_request] + +jobs: + typechecking: + runs-on: ubuntu-latest + strategy: + max-parallel: 4 + matrix: + python-version: [3.6, 3.7, 3.8, 3.9, 3.10, 3.11] + steps: + - uses: actions/checkout@v2 + - name: Setup Python 3.11 + uses: actions/setup-python@v4.5.0 + with: + python-version: "3.11" + - name: Install Dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements-dev.txt + pip install mypy + + - name: Run type checking + run: | + mypy -p pypika --python-version ${{ matrix.python-version }} From ed7d67a502da4084ccee8b2b42d61dac3e54d9a5 Mon Sep 17 00:00:00 2001 From: Rubicon Rowe Date: Mon, 27 Feb 2023 22:11:43 +0800 Subject: [PATCH 2/5] Removed parallel limit --- .github/workflows/typechecking.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/typechecking.yml b/.github/workflows/typechecking.yml index 29da9f6f..a7bdd0d0 100644 --- a/.github/workflows/typechecking.yml +++ b/.github/workflows/typechecking.yml @@ -6,7 +6,6 @@ jobs: typechecking: runs-on: ubuntu-latest strategy: - max-parallel: 4 matrix: python-version: [3.6, 3.7, 3.8, 3.9, 3.10, 3.11] steps: From 914be157f5dc3db4e76f677c4200edb1d22dfa90 Mon Sep 17 00:00:00 2001 From: Rubicon Rowe Date: Mon, 27 Feb 2023 22:20:48 +0800 Subject: [PATCH 3/5] ci/typechecking: Limit triggers --- .github/workflows/typechecking.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/typechecking.yml b/.github/workflows/typechecking.yml index a7bdd0d0..bc695f72 100644 --- a/.github/workflows/typechecking.yml +++ b/.github/workflows/typechecking.yml @@ -1,6 +1,12 @@ name: "Type Checking" -on: [push, pull_request] +on: + push: + branches: ["master"] + pull_request: + types: [opened, reopened, review_requested] + paths: + - "**.py" jobs: typechecking: @@ -10,10 +16,8 @@ jobs: python-version: [3.6, 3.7, 3.8, 3.9, 3.10, 3.11] steps: - uses: actions/checkout@v2 - - name: Setup Python 3.11 + - name: Setup Python uses: actions/setup-python@v4.5.0 - with: - python-version: "3.11" - name: Install Dependencies run: | python -m pip install --upgrade pip From e3f8449968d229e41fa71b4bf94398ab62d51e1e Mon Sep 17 00:00:00 2001 From: Rubicon Rowe Date: Mon, 27 Feb 2023 22:23:35 +0800 Subject: [PATCH 4/5] ci/typechecking: Set trigger to push --- .github/workflows/typechecking.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/typechecking.yml b/.github/workflows/typechecking.yml index bc695f72..1b8d5d53 100644 --- a/.github/workflows/typechecking.yml +++ b/.github/workflows/typechecking.yml @@ -1,12 +1,6 @@ name: "Type Checking" -on: - push: - branches: ["master"] - pull_request: - types: [opened, reopened, review_requested] - paths: - - "**.py" +on: push jobs: typechecking: From f68dedc74ad1f3bf4e2cf79afe73bf1d240e74d3 Mon Sep 17 00:00:00 2001 From: Rubicon Rowe Date: Mon, 27 Feb 2023 22:26:10 +0800 Subject: [PATCH 5/5] ci/typechecking: fixed using python 3.11 - fixed CI using python 3.1 instead of 3.10 --- .github/workflows/typechecking.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/typechecking.yml b/.github/workflows/typechecking.yml index 1b8d5d53..ec3ad083 100644 --- a/.github/workflows/typechecking.yml +++ b/.github/workflows/typechecking.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.6, 3.7, 3.8, 3.9, 3.10, 3.11] + python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11"] steps: - uses: actions/checkout@v2 - name: Setup Python