From 01be4f126737adc5ee208335a104210244e5bef4 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Thu, 9 Jun 2022 16:02:07 +0200 Subject: [PATCH 1/7] Use setup-conda action --- .github/actions/setup-conda/action.yml | 10 +++++++++- .github/workflows/asv-bot.yml | 8 ++------ .github/workflows/code-checks.yml | 20 ++++---------------- .github/workflows/posix.yml | 17 +++++------------ .github/workflows/sdist.yml | 8 ++++---- 5 files changed, 24 insertions(+), 39 deletions(-) diff --git a/.github/actions/setup-conda/action.yml b/.github/actions/setup-conda/action.yml index 1c947ff244fb9..005825556d10f 100644 --- a/.github/actions/setup-conda/action.yml +++ b/.github/actions/setup-conda/action.yml @@ -3,6 +3,12 @@ inputs: environment-file: description: Conda environment file to use. default: environment.yml + environment-name: + description: Name to use for the Conda environment + required: false + python-version: + description: Python version to install + required: false pyarrow-version: description: If set, overrides the PyArrow version in the Conda environment to the given string. required: false @@ -21,7 +27,9 @@ runs: uses: conda-incubator/setup-miniconda@v2 with: environment-file: ${{ inputs.environment-file }} + activate-environment: ${{ inputs.environment-name }} + python-version: ${{ inputs.python-version }} channel-priority: ${{ runner.os == 'macOS' && 'flexible' || 'strict' }} channels: conda-forge - mamba-version: "0.23" + mamba-version: "0.24" use-mamba: true diff --git a/.github/workflows/asv-bot.yml b/.github/workflows/asv-bot.yml index 78c224b84d5d9..022c12cf6ff6c 100644 --- a/.github/workflows/asv-bot.yml +++ b/.github/workflows/asv-bot.yml @@ -41,12 +41,8 @@ jobs: # Although asv sets up its own env, deps are still needed # during discovery process - - uses: conda-incubator/setup-miniconda@v2.1.1 - with: - activate-environment: pandas-dev - channel-priority: strict - environment-file: ${{ env.ENV_FILE }} - use-only-tar-bz2: true + - name: Set up Conda + uses: ./.github/actions/setup-conda - name: Run benchmarks id: bench diff --git a/.github/workflows/code-checks.yml b/.github/workflows/code-checks.yml index 7812c4dd00bcb..85d8bedb95708 100644 --- a/.github/workflows/code-checks.yml +++ b/.github/workflows/code-checks.yml @@ -58,14 +58,8 @@ jobs: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ hashFiles('${{ env.ENV_FILE }}') }} - - uses: conda-incubator/setup-miniconda@v2.1.1 - with: - mamba-version: "*" - channels: conda-forge - activate-environment: pandas-dev - channel-priority: strict - environment-file: ${{ env.ENV_FILE }} - use-only-tar-bz2: true + - Name: Set up Conda + uses: ./.github/actions/setup-conda - name: Build Pandas id: build @@ -127,14 +121,8 @@ jobs: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ hashFiles('${{ env.ENV_FILE }}') }} - - uses: conda-incubator/setup-miniconda@v2.1.1 - with: - mamba-version: "*" - channels: conda-forge - activate-environment: pandas-dev - channel-priority: strict - environment-file: ${{ env.ENV_FILE }} - use-only-tar-bz2: true + - name: Set up Conda + uses: ./.github/actions/setup-conda - name: Build Pandas id: build diff --git a/.github/workflows/posix.yml b/.github/workflows/posix.yml index 35c40f2a4aa54..f3c70d56024e2 100644 --- a/.github/workflows/posix.yml +++ b/.github/workflows/posix.yml @@ -24,11 +24,11 @@ jobs: timeout-minutes: 120 strategy: matrix: - env_file: [actions-38.yaml, actions-39.yaml, actions-310.yaml] + env_file: [actions-38.yaml] #, actions-39.yaml, actions-310.yaml] pattern: ["not single_cpu", "single_cpu"] # Don't test pyarrow v2/3: Causes timeouts in read_csv engine # even if tests are skipped/xfailed - pyarrow_version: ["5", "6", "7"] + pyarrow_version: ["5"] #, "6", "7"] include: - name: "Downstream Compat" env_file: actions-38-downstream_compat.yaml @@ -147,18 +147,11 @@ jobs: # xsel for clipboard tests run: sudo apt-get update && sudo apt-get install -y libc6-dev-i386 xsel ${{ env.EXTRA_APT }} - - uses: conda-incubator/setup-miniconda@v2.1.1 + - name: Set up Conda + uses: ./.github/actions/setup-conda with: - mamba-version: "*" - channels: conda-forge - activate-environment: pandas-dev - channel-priority: flexible environment-file: ${{ env.ENV_FILE }} - use-only-tar-bz2: true - - - name: Upgrade Arrow version - run: conda install -n pandas-dev -c conda-forge --no-update-deps pyarrow=${{ matrix.pyarrow_version }} - if: ${{ matrix.pyarrow_version }} + pyarrow-version: ${{ matrix.pyarrow_version }} - name: Build Pandas uses: ./.github/actions/build_pandas diff --git a/.github/workflows/sdist.yml b/.github/workflows/sdist.yml index e4bb556359177..d97490d5494c3 100644 --- a/.github/workflows/sdist.yml +++ b/.github/workflows/sdist.yml @@ -59,11 +59,11 @@ jobs: name: ${{matrix.python-version}}-sdist.gz path: dist/*.gz - - uses: conda-incubator/setup-miniconda@v2.1.1 + - name: Set up Conda + uses: ./.github/actions/setup-conda with: - activate-environment: pandas-sdist - channels: conda-forge - python-version: '${{ matrix.python-version }}' + environment-name: pandas-sdist + python-version: ${{ matrix.python-version }} - name: Install pandas from sdist run: | From 729e5806d6f1e4228e40ce54eaa07f731753f5d2 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Thu, 9 Jun 2022 16:42:28 +0200 Subject: [PATCH 2/7] Update action.yml --- .github/actions/setup-conda/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/setup-conda/action.yml b/.github/actions/setup-conda/action.yml index 005825556d10f..4905b142a4e93 100644 --- a/.github/actions/setup-conda/action.yml +++ b/.github/actions/setup-conda/action.yml @@ -5,7 +5,7 @@ inputs: default: environment.yml environment-name: description: Name to use for the Conda environment - required: false + default: test python-version: description: Python version to install required: false From c9927837a02a597a9a6501834cd95d71856226a2 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Thu, 9 Jun 2022 17:55:22 +0200 Subject: [PATCH 3/7] Update posix.yml --- .github/workflows/posix.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/posix.yml b/.github/workflows/posix.yml index f3c70d56024e2..061b2b361ca62 100644 --- a/.github/workflows/posix.yml +++ b/.github/workflows/posix.yml @@ -24,11 +24,11 @@ jobs: timeout-minutes: 120 strategy: matrix: - env_file: [actions-38.yaml] #, actions-39.yaml, actions-310.yaml] + env_file: [actions-38.yaml, actions-39.yaml, actions-310.yaml] pattern: ["not single_cpu", "single_cpu"] # Don't test pyarrow v2/3: Causes timeouts in read_csv engine # even if tests are skipped/xfailed - pyarrow_version: ["5"] #, "6", "7"] + pyarrow_version: ["5", "6", "7"] include: - name: "Downstream Compat" env_file: actions-38-downstream_compat.yaml From 02cd874f8b6566812a755433f8a43162e9d0eb37 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Thu, 9 Jun 2022 20:41:27 +0200 Subject: [PATCH 4/7] Update sdist.yml --- .github/workflows/sdist.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sdist.yml b/.github/workflows/sdist.yml index d97490d5494c3..ca4ebef0f8fd1 100644 --- a/.github/workflows/sdist.yml +++ b/.github/workflows/sdist.yml @@ -15,7 +15,7 @@ on: jobs: build: - if: ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}} + #if: ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}} runs-on: ubuntu-latest timeout-minutes: 60 defaults: From 3723a3f1154a670092387adffd07b99a992e5f71 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Thu, 9 Jun 2022 21:20:21 +0200 Subject: [PATCH 5/7] Update sdist.yml --- .github/workflows/sdist.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/sdist.yml b/.github/workflows/sdist.yml index ca4ebef0f8fd1..1df51a01a52b7 100644 --- a/.github/workflows/sdist.yml +++ b/.github/workflows/sdist.yml @@ -62,6 +62,7 @@ jobs: - name: Set up Conda uses: ./.github/actions/setup-conda with: + environment-file: "" environment-name: pandas-sdist python-version: ${{ matrix.python-version }} From f5274fd87d8554cd8677ed8dc7376e6629ba9373 Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Fri, 10 Jun 2022 16:28:39 +0200 Subject: [PATCH 6/7] Update sdist.yml --- .github/workflows/sdist.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sdist.yml b/.github/workflows/sdist.yml index 1df51a01a52b7..5ae2280c5069f 100644 --- a/.github/workflows/sdist.yml +++ b/.github/workflows/sdist.yml @@ -15,7 +15,7 @@ on: jobs: build: - #if: ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}} + if: ${{ github.event.label.name == 'Build' || contains(github.event.pull_request.labels.*.name, 'Build') || github.event_name == 'push'}} runs-on: ubuntu-latest timeout-minutes: 60 defaults: From 489526b4f535ebb6fee5d08e1078b16f1568a4bb Mon Sep 17 00:00:00 2001 From: Jonas Haag Date: Fri, 10 Jun 2022 21:31:33 +0200 Subject: [PATCH 7/7] Update action.yml --- .github/actions/setup-conda/action.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/actions/setup-conda/action.yml b/.github/actions/setup-conda/action.yml index fdc8647b0d480..87a0bd2ed1715 100644 --- a/.github/actions/setup-conda/action.yml +++ b/.github/actions/setup-conda/action.yml @@ -33,4 +33,5 @@ runs: channels: conda-forge mamba-version: "0.24" use-mamba: true + use-only-tar-bz2: true condarc-file: ci/condarc.yml