From d29865a7ac2a591068aba849f333c0f60a3f6e4d Mon Sep 17 00:00:00 2001 From: Mahdi Ben Jelloul Date: Tue, 1 Oct 2024 18:52:22 +0100 Subject: [PATCH] Remove conda stuff --- .github/get_pypi_info.py | 0 .github/workflows/workflow.yml | 182 ++++++++++++++++----------------- 2 files changed, 91 insertions(+), 91 deletions(-) mode change 100644 => 100755 .github/get_pypi_info.py diff --git a/.github/get_pypi_info.py b/.github/get_pypi_info.py old mode 100644 new mode 100755 diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml index 3c667e14..b830879c 100644 --- a/.github/workflows/workflow.yml +++ b/.github/workflows/workflow.yml @@ -231,96 +231,96 @@ jobs: - name: Publish a git tag run: "${GITHUB_WORKSPACE}/.github/publish-git-tag.sh" - build-conda: - runs-on: "ubuntu-20.04" - needs: [ check-version-and-changelog ] - # Do not build on master, the artifact will be used - if: github.ref != 'refs/heads/master' - steps: - - uses: conda-incubator/setup-miniconda@v2 - with: - auto-update-conda: true - python-version: "3.9.9" - # Add conda-forge for OpenFisca-Core - channels: openfisca,conda-forge - activate-environment: true - - uses: actions/checkout@v3 - - name: Update meta.yaml - run: | - python3 -m pip install requests argparse - python3 .github/get_pypi_info.py -p OpenFisca-Tunisia - - name: Get version - run: echo "PACKAGE_VERSION=$(python3 ./setup.py --version)" >> $GITHUB_ENV - - name: Conda Config - run: | - conda install conda-build anaconda-client - conda info - - name: Build Conda package - run: conda build -c openfisca -c conda-forge --croot /tmp/conda .conda - - name: Upload Conda build - uses: actions/upload-artifact@v3 - with: - name: conda-build-${{ env.PACKAGE_VERSION }}-${{ github.sha }} - path: /tmp/conda - retention-days: 30 + # build-conda: + # runs-on: "ubuntu-20.04" + # needs: [ check-version-and-changelog ] + # # Do not build on master, the artifact will be used + # if: github.ref != 'refs/heads/master' + # steps: + # - uses: conda-incubator/setup-miniconda@v2 + # with: + # auto-update-conda: true + # python-version: "3.9.9" + # # Add conda-forge for OpenFisca-Core + # channels: openfisca,conda-forge + # activate-environment: true + # - uses: actions/checkout@v3 + # - name: Update meta.yaml + # run: | + # python3 -m pip install requests argparse + # python3 .github/get_pypi_info.py -p OpenFisca-Tunisia + # - name: Get version + # run: echo "PACKAGE_VERSION=$(python3 ./setup.py --version)" >> $GITHUB_ENV + # - name: Conda Config + # run: | + # conda install conda-build anaconda-client + # conda info + # - name: Build Conda package + # run: conda build -c openfisca -c conda-forge --croot /tmp/conda .conda + # - name: Upload Conda build + # uses: actions/upload-artifact@v3 + # with: + # name: conda-build-${{ env.PACKAGE_VERSION }}-${{ github.sha }} + # path: /tmp/conda + # retention-days: 30 - test-on-windows: - runs-on: "windows-latest" - needs: [ build-conda ] - steps: - - uses: conda-incubator/setup-miniconda@v2 - with: - auto-update-conda: true - python-version: "3.9.9" - # Add conda-forge for OpenFisca-Core - channels: openfisca,conda-forge - activate-environment: true - - uses: actions/checkout@v3 - - name: Test max path length - run: "python3 openfisca_tunisia/scripts/check_path_length.py" - - name: Get version - run: | - # chcp 65001 #set code page to utf-8 - echo ("PACKAGE_VERSION=" + (python3 ./setup.py --version) ) >> $env:GITHUB_ENV - echo "Version setup.py: ${{ env.PACKAGE_VERSION }}" - - name: Download conda build - uses: actions/download-artifact@v3 - with: - name: conda-build-${{ env.PACKAGE_VERSION }}-${{ github.sha }} - path: conda-build-tmp - - name: Install with conda - run: | - conda install -c ./conda-build-tmp/noarch/openfisca-tunisia-dev-${{ env.PACKAGE_VERSION }}-py_0.tar.bz2 openfisca-tunisia-dev - - name: openfisca test - run: openfisca test --country-package openfisca_tunisia tests + # test-on-windows: + # runs-on: "windows-latest" + # needs: [ build-conda ] + # steps: + # - uses: conda-incubator/setup-miniconda@v2 + # with: + # auto-update-conda: true + # python-version: "3.9.9" + # # Add conda-forge for OpenFisca-Core + # channels: openfisca,conda-forge + # activate-environment: true + # - uses: actions/checkout@v3 + # - name: Test max path length + # run: "python3 openfisca_tunisia/scripts/check_path_length.py" + # - name: Get version + # run: | + # # chcp 65001 #set code page to utf-8 + # echo ("PACKAGE_VERSION=" + (python3 ./setup.py --version) ) >> $env:GITHUB_ENV + # echo "Version setup.py: ${{ env.PACKAGE_VERSION }}" + # - name: Download conda build + # uses: actions/download-artifact@v3 + # with: + # name: conda-build-${{ env.PACKAGE_VERSION }}-${{ github.sha }} + # path: conda-build-tmp + # - name: Install with conda + # run: | + # conda install -c ./conda-build-tmp/noarch/openfisca-tunisia-dev-${{ env.PACKAGE_VERSION }}-py_0.tar.bz2 openfisca-tunisia-dev + # - name: openfisca test + # run: openfisca test --country-package openfisca_tunisia tests - publish-to-conda: - runs-on: "ubuntu-20.04" - needs: [ deploy ] - steps: - - uses: conda-incubator/setup-miniconda@v2 - with: - auto-update-conda: true - python-version: "3.9.9" - # Add conda-forge for OpenFisca-Core - channels: conda-forge - activate-environment: true - - name: Get source code - uses: actions/checkout@v3 - - name: Get version - run: echo "PACKAGE_VERSION=$(python3 ./setup.py --version)" >> $GITHUB_ENV - # Get the last commit hash on the PR (-2 : before the merge commit) - - uses: actions/github-script@v6 - id: last_pr_commit - with: - script: | - const commits = ${{ toJSON(github.event.commits) }} - return commits.at(-2).id; - result-encoding: string - - name: Conda build and upload - # This shell is made necessary by https://github.com/conda-incubator/setup-miniconda/issues/128 - shell: bash -l {0} - run: | - conda install --yes conda-build anaconda-client - conda config --set anaconda_upload yes - conda build --channel conda-forge --channel openfisca --token ${{ secrets.ANACONDA_TOKEN }} --user openfisca .conda + # publish-to-conda: + # runs-on: "ubuntu-20.04" + # needs: [ deploy ] + # steps: + # - uses: conda-incubator/setup-miniconda@v2 + # with: + # auto-update-conda: true + # python-version: "3.9.9" + # # Add conda-forge for OpenFisca-Core + # channels: conda-forge + # activate-environment: true + # - name: Get source code + # uses: actions/checkout@v3 + # - name: Get version + # run: echo "PACKAGE_VERSION=$(python3 ./setup.py --version)" >> $GITHUB_ENV + # # Get the last commit hash on the PR (-2 : before the merge commit) + # - uses: actions/github-script@v6 + # id: last_pr_commit + # with: + # script: | + # const commits = ${{ toJSON(github.event.commits) }} + # return commits.at(-2).id; + # result-encoding: string + # - name: Conda build and upload + # # This shell is made necessary by https://github.com/conda-incubator/setup-miniconda/issues/128 + # shell: bash -l {0} + # run: | + # conda install --yes conda-build anaconda-client + # conda config --set anaconda_upload yes + # conda build --channel conda-forge --channel openfisca --token ${{ secrets.ANACONDA_TOKEN }} --user openfisca .conda