From 7ac04128b2121b4b8939c862e0c7a91048f9e5ea Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Thu, 28 Sep 2023 18:02:12 -0500 Subject: [PATCH 01/19] Initial pass --- ci/github/.condarc => .github/condarc | 12 +- .github/workflows/tests.yml | 230 +++++++++++++------------- .pre-commit-config.yaml | 6 +- conda_build/conda_interface.py | 15 +- conda_build/metadata.py | 16 +- conda_build/utils.py | 8 +- pyproject.toml | 14 +- tests/requirements-Linux.txt | 3 + tests/requirements-Windows.txt | 2 + tests/requirements-linux.txt | 5 - tests/requirements-macOS.txt | 2 + tests/requirements-macos.txt | 4 - tests/requirements-windows.txt | 4 - tests/requirements.txt | 4 +- 14 files changed, 159 insertions(+), 166 deletions(-) rename ci/github/.condarc => .github/condarc (70%) create mode 100644 tests/requirements-Linux.txt create mode 100644 tests/requirements-Windows.txt delete mode 100644 tests/requirements-linux.txt create mode 100644 tests/requirements-macOS.txt delete mode 100644 tests/requirements-macos.txt delete mode 100644 tests/requirements-windows.txt diff --git a/ci/github/.condarc b/.github/condarc similarity index 70% rename from ci/github/.condarc rename to .github/condarc index 44a36fcc35..3e984acc9b 100644 --- a/ci/github/.condarc +++ b/.github/condarc @@ -1,8 +1,10 @@ -auto_update_conda: False +always_yes: True auto_activate_base: True -notify_outdated_conda: False +auto_update_conda: False changeps1: False -pkgs_dirs: -- /usr/share/miniconda/envs/test/pkgs -always_yes: True +channels: + - defaults local_repodata_ttl: 7200 +notify_outdated_conda: False +pkgs_dirs: + - /usr/share/miniconda/envs/test/pkgs diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9778c04d23..e1d1bfe073 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,6 +1,3 @@ -# this is the sibling workflow to tests-skip.yml, it is required to work around -# the skipped but required checks issue: -# https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/troubleshooting-required-status-checks#handling-skipped-but-required-checks name: Tests on: @@ -36,6 +33,8 @@ jobs: changes: runs-on: ubuntu-latest permissions: + # necessary to detect changes + # https://github.com/dorny/paths-filter#supported-workflows pull-requests: read outputs: code: ${{ steps.filter.outputs.code }} @@ -44,6 +43,7 @@ jobs: # dorny/paths-filter needs git clone for non-PR events # https://github.com/marketplace/actions/paths-changes-filter#supported-workflows if: github.event_name != 'pull_request' + - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 id: filter with: @@ -64,32 +64,37 @@ jobs: runs-on: ubuntu-latest defaults: run: + # https://github.com/conda-incubator/setup-miniconda#use-a-default-shell shell: bash -l {0} strategy: fail-fast: false matrix: # test all lower versions (w/ stable conda) and upper version (w/ canary conda) - python-version: ['3.8', '3.9', '3.10'] - conda-version: [release] + python-version: ['3.8', '3.9', '3.10', '3.11'] + conda-version: [release, canary] test-type: [serial, parallel] - include: - - python-version: '3.11' + test-group: [1, 2, 3] + exclude: + - python-version: '3.8' conda-version: canary - test-type: serial - - python-version: '3.11' + - python-version: '3.9' conda-version: canary - test-type: parallel + - python-version: '3.10' + conda-version: canary + - python-version: '3.11' + conda-version: release + - test-type: serial + test-group: 3 env: - CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} - REPLAY_NAME: Linux-${{ matrix.conda-version }}-Py${{ matrix.python-version }} - REPLAY_DIR: ${{ github.workspace }}/pytest-replay ALLURE_DIR: ${{ github.workspace }}/allure-results + CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} + HASH: ${{ runner.os }}-${{ runner.arch }}-${{ matrix.default-channel }}-Py${{ matrix.python-version }}-${{ matrix.test-type }}-${{ matrix.test-group }} steps: - - name: Checkout repository - uses: actions/checkout@v3 + - uses: actions/checkout@v3 with: fetch-depth: 0 @@ -101,18 +106,18 @@ jobs: uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ runner.os }}-conda-${{ env.TIMESTAMP }} + key: ${{ env.HASH }}-${{ env.TIMESTAMP }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 with: - condarc-file: ./ci/github/.condarc + condarc-file: .github/condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - name: Setup environment run: | - conda install -q -y -c defaults \ + conda install --quiet --yes \ --file ./tests/requirements.txt \ --file ./tests/requirements-linux.txt \ ${{ env.CONDA_CHANNEL_LABEL }}::conda @@ -120,29 +125,32 @@ jobs: - name: Show info run: | - conda info -a + conda info --verbose conda list --show-channel-urls - name: Run tests run: | pytest \ - --color=yes \ - -v \ - -n "${{ env.PYTEST_NUMPROCESSES }}" \ - --basetemp "${{ runner.temp }}/${{ matrix.test-type }}" \ - --cov conda_build \ - --cov-append \ - --cov-branch \ - --cov-report xml \ - --replay-record-dir="${{ env.REPLAY_DIR }}" \ - --replay-base-name="${{ env.REPLAY_NAME }}" \ --alluredir="${{ env.ALLURE_DIR }}" \ - -m "${{ env.PYTEST_MARKER }}" \ - ./tests + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ + --cov=conda_build \ + --durations-path="./tools/durations/${{ runner.os }}.json" \ + --group=${{ matrix.test-group }} \ + --splits=${{ env.PYTEST_SPLITS }} \ + -n "${{ env.PYTEST_NUMPROCESSES }}" \ + -m "${{ env.PYTEST_MARKER }}" - uses: codecov/codecov-action@v3 with: - flags: ${{ matrix.test-type }},${{ matrix.python-version }},linux-64 + flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} + + - name: Upload durations + if: '!cancelled()' + uses: actions/upload-artifact@v3 + with: + name: durations-${{ env.HASH }} + path: ./tools/durations/${{ runner.os }}.json + retention-days: 7 # for durations.yml workflow - name: Tar Allure Results if: '!cancelled()' @@ -152,15 +160,8 @@ jobs: if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: allure-Linux-${{ matrix.conda-version }}-Py${{ matrix.python-version }}-${{ matrix.test-type }} - path: allure-results.tar.gz - - - name: Upload Pytest Replay - if: '!cancelled()' - uses: actions/upload-artifact@v3 - with: - name: ${{ env.REPLAY_NAME }}-${{ matrix.test-type }} - path: ${{ env.REPLAY_DIR }} + name: allure-${{ env.HASH }} + path: ${{ env.ALLURE_DIR }} # windows test suite windows: @@ -168,32 +169,32 @@ jobs: needs: changes if: github.event_name == 'schedule' || needs.changes.outputs.code == 'true' - runs-on: windows-2019 + runs-on: windows-latest strategy: fail-fast: false matrix: # test lower version (w/ stable conda) and upper version (w/ canary conda) - python-version: ['3.8'] - conda-version: [release] + python-version: ['3.8', '3.11'] + conda-version: [release, canary] test-type: [serial, parallel] - include: - - python-version: '3.11' + test-group: [1, 2, 3] + exclude: + - python-version: '3.8' conda-version: canary - test-type: serial - python-version: '3.11' - conda-version: canary - test-type: parallel + conda-version: release + - test-type: serial + test-group: 3 env: - CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} - REPLAY_NAME: Win-${{ matrix.conda-version }}-Py${{ matrix.python-version }} - REPLAY_DIR: ${{ github.workspace }}\pytest-replay ALLURE_DIR: ${{ github.workspace }}\allure-results + CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial and not slow' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} + HASH: ${{ runner.os }}-${{ runner.arch }}-${{ matrix.default-channel }}-Py${{ matrix.python-version }}-${{ matrix.test-type }}-${{ matrix.test-group }} steps: - - name: Checkout repository - uses: actions/checkout@v3 + - uses: actions/checkout@v3 with: fetch-depth: 0 @@ -205,49 +206,52 @@ jobs: uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ runner.os }}-conda-${{ env.TIMESTAMP }} + key: ${{ env.HASH }}-${{ env.TIMESTAMP }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 with: - condarc-file: .\ci\github\.condarc + condarc-file: .github\condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - name: Setup environment run: | choco install visualstudio2017-workload-vctools - conda install -q -y -c defaults ` + conda install --quiet --yes ` --file .\tests\requirements.txt ` - --file .\tests\requirements-windows.txt ` + --file .\tests\requirements-${{ runner.os }}.txt ` ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . - name: Show info run: | - conda info -a + conda info --verbose conda list --show-channel-urls - name: Run tests run: | pytest ` - --color=yes ` - -v ` - -n "${{ env.PYTEST_NUMPROCESSES }}" ` - --basetemp "${{ runner.temp }}\${{ matrix.test-type}}" ` - --cov conda_build ` - --cov-append ` - --cov-branch ` - --cov-report xml ` - --replay-record-dir="${{ env.REPLAY_DIR }}" ` - --replay-base-name="${{ env.REPLAY_NAME }}" ` --alluredir="${{ env.ALLURE_DIR }}" ` + --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" ` + --cov=conda_build ` + --durations-path=".\tools\durations\${{ runner.os }}.json" ` + --group=${{ matrix.test-group }} ` + --splits=${{ env.PYTEST_SPLITS }} ` -m "${{ env.PYTEST_MARKER }}" ` - .\tests + -n "${{ env.PYTEST_NUMPROCESSES }}" - uses: codecov/codecov-action@v3 with: - flags: ${{ matrix.test-type }},${{ matrix.python-version }},win-64 + flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} + + - name: Upload test results + if: '!cancelled()' + uses: actions/upload-artifact@v3 + with: + name: durations-${{ env.HASH }} + path: .\tools\durations\${{ runner.os }}.json + retention-days: 7 # for durations.yml workflow - name: Tar Allure Results if: '!cancelled()' @@ -260,15 +264,8 @@ jobs: if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: allure-Win-${{ matrix.conda-version }}-Py${{ matrix.python-version }}-${{ matrix.test-type }} - path: allure-results.tar.gz - - - name: Upload Pytest Replay - if: '!cancelled()' - uses: actions/upload-artifact@v3 - with: - path: ${{ env.REPLAY_DIR }} - name: ${{ env.REPLAY_NAME }}-${{ matrix.test-type }} + name: allure-${{ env.HASH }} + path: "${{ env.ALLURE_DIR }}" # macos test suite macos: @@ -276,35 +273,34 @@ jobs: needs: changes if: github.event_name == 'schedule' || needs.changes.outputs.code == 'true' - runs-on: macos-11 + runs-on: macos-latest defaults: run: + # https://github.com/conda-incubator/setup-miniconda#use-a-default-shell shell: bash -l {0} strategy: fail-fast: false matrix: # test lower version (w/ stable conda) and upper version (w/ canary conda) - python-version: ['3.8'] - conda-version: [release] + python-version: ['3.8', '3.11'] + conda-version: [release, canary] test-type: [serial, parallel] - include: - - python-version: '3.11' + test-group: [1, 2, 3] + exclude: + - python-version: '3.8' conda-version: canary - test-type: serial - python-version: '3.11' - conda-version: canary - test-type: parallel + conda-version: release + - test-type: serial + test-group: 3 env: - CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} - REPLAY_NAME: macOS-${{ matrix.conda-version }}-Py${{ matrix.python-version }} - REPLAY_DIR: ${{ github.workspace }}/pytest-replay ALLURE_DIR: ${{ github.workspace }}/allure-results + CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} steps: - - name: Checkout repository - uses: actions/checkout@v3 + - uses: actions/checkout@v3 with: fetch-depth: 0 @@ -316,49 +312,52 @@ jobs: uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ runner.os }}-conda-${{ env.TIMESTAMP }} + key: ${{ env.HASH }}-${{ env.TIMESTAMP }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 with: - condarc-file: ./ci/github/.condarc + condarc-file: .github/condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - name: Setup environment run: | sudo xcode-select --switch /Applications/Xcode_11.7.app - conda install -q -y -c defaults \ + conda install --quiet --yes \ --file ./tests/requirements.txt \ - --file ./tests/requirements-macos.txt \ + --file ./tests/requirements-${{ runner.os }}.txt \ ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . - name: Show info run: | - conda info -a + conda info --verbose conda list --show-channel-urls - name: Run tests run: | pytest \ - --color=yes \ - -v \ - -n "${{ env.PYTEST_NUMPROCESSES }}" \ - --basetemp "${{ runner.temp }}/${{ matrix.test-type }}" \ - --cov conda_build \ - --cov-append \ - --cov-branch \ - --cov-report xml \ - --replay-record-dir="${{ env.REPLAY_DIR }}" \ - --replay-base-name="${{ env.REPLAY_NAME }}" \ --alluredir="${{ env.ALLURE_DIR }}" \ + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ + --cov=conda_build \ + --durations-path=./tools/durations/${{ runner.os }}.json \ + --group=${{ matrix.test-group }} \ + --splits=${{ env.PYTEST_SPLITS }} \ -m "${{ env.PYTEST_MARKER }}" \ - ./tests + -n "${{ env.PYTEST_NUMPROCESSES }}" - uses: codecov/codecov-action@v3 with: - flags: ${{ matrix.test-type }},${{ matrix.python-version }},osx-64 + flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} + + - name: Upload durations + if: '!cancelled()' + uses: actions/upload-artifact@v3 + with: + name: durations-${{ env.HASH }} + path: ./tools/durations/${{ runner.os }}.json + retention-days: 7 # for duration.yml workflow - name: Tar Allure Results if: '!cancelled()' @@ -368,15 +367,8 @@ jobs: if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: allure-macOS-${{ matrix.conda-version }}-Py${{ matrix.python-version }}-${{ matrix.test-type }} - path: allure-results.tar.gz - - - name: Upload Pytest Replay - if: '!cancelled()' - uses: actions/upload-artifact@v3 - with: - name: ${{ env.REPLAY_NAME }}-${{ matrix.test-type }} - path: ${{ env.REPLAY_DIR }} + name: allure-${{ env.HASH }} + path: ${{ env.ALLURE_DIR }} # aggregate and upload aggregate: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 34f2c97018..ae9caec20c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,7 +12,7 @@ exclude: | test-recipes | test-skeleton )/ | - .*\.(patch|diff) | + .*\.(patch|diff) ) repos: # generic verification and formatting @@ -35,6 +35,10 @@ repos: ) # catch git merge/rebase problems - id: check-merge-conflict + # sort requirements files + - id: file-contents-sorter + files: ^tests/requirements.*\.txt + args: [--unique] # Python verification and formatting - repo: https://github.com/Lucas-C/pre-commit-hooks rev: v1.5.4 diff --git a/conda_build/conda_interface.py b/conda_build/conda_interface.py index 92d5ba0678..25ecc9cef9 100644 --- a/conda_build/conda_interface.py +++ b/conda_build/conda_interface.py @@ -11,9 +11,8 @@ from conda.auxlib.packaging import ( # noqa: F401 _get_version_from_git_tag as get_version_from_git_tag, ) -from conda.base.context import context, determine_target_prefix +from conda.base.context import context, determine_target_prefix, reset_context from conda.base.context import non_x86_machines as non_x86_linux_machines # noqa: F401 -from conda.base.context import reset_context from conda.core.package_cache import ProgressiveFetchExtract # noqa: F401 from conda.exceptions import ( # noqa: F401 CondaError, @@ -24,15 +23,12 @@ PaddingError, UnsatisfiableError, ) -from conda.exports import ArgumentParser # noqa: F401 -from conda.exports import CondaSession # noqa: F401 -from conda.exports import EntityEncoder # noqa: F401 -from conda.exports import VersionOrder # noqa: F401 -from conda.exports import _toposort # noqa: F401 -from conda.exports import get_index # noqa: F401 from conda.exports import ( # noqa: F401 + ArgumentParser, # noqa: F401 Channel, Completer, + CondaSession, # noqa: F401 + EntityEncoder, # noqa: F401 FileMode, InstalledPackages, MatchSpec, @@ -43,12 +39,15 @@ TemporaryDirectory, TmpDownload, Unsatisfiable, + VersionOrder, # noqa: F401 + _toposort, # noqa: F401 add_parser_channels, add_parser_prefix, display_actions, download, execute_actions, execute_plan, + get_index, # noqa: F401 handle_proxy_407, hashsum_file, human_bytes, diff --git a/conda_build/metadata.py b/conda_build/metadata.py index 47f3166727..0681bcf90c 100644 --- a/conda_build/metadata.py +++ b/conda_build/metadata.py @@ -1752,18 +1752,20 @@ def has_prefix_files(self): def ignore_prefix_files(self): ret = self.get_value("build/ignore_prefix_files", False) - if type(ret) not in (list, bool): + if not isinstance(ret, (list, bool)): raise RuntimeError( "build/ignore_prefix_files should be boolean or a list of paths " "(optionally globs)" ) if sys.platform == "win32": - if type(ret) is list and any("\\" in i for i in ret): + if isinstance(ret, list) and any("\\" in i for i in ret): raise RuntimeError( "build/ignore_prefix_files paths must use / " "as the path delimiter on Windows" ) - return expand_globs(ret, self.config.host_prefix) if type(ret) is list else ret + return ( + expand_globs(ret, self.config.host_prefix) if isinstance(ret, list) else ret + ) def always_include_files(self): files = ensure_list(self.get_value("build/always_include_files", [])) @@ -1782,18 +1784,20 @@ def ignore_verify_codes(self): def binary_relocation(self): ret = self.get_value("build/binary_relocation", True) - if type(ret) not in (list, bool): + if not isinstance(ret, (list, bool)): raise RuntimeError( "build/binary_relocation should be boolean or a list of paths " "(optionally globs)" ) if sys.platform == "win32": - if type(ret) is list and any("\\" in i for i in ret): + if isinstance(ret, list) and any("\\" in i for i in ret): raise RuntimeError( "build/binary_relocation paths must use / " "as the path delimiter on Windows" ) - return expand_globs(ret, self.config.host_prefix) if type(ret) is list else ret + return ( + expand_globs(ret, self.config.host_prefix) if isinstance(ret, list) else ret + ) def include_recipe(self): return self.get_value("build/include_recipe", True) diff --git a/conda_build/utils.py b/conda_build/utils.py index a62d6700be..af5678247e 100644 --- a/conda_build/utils.py +++ b/conda_build/utils.py @@ -73,15 +73,15 @@ from conda_build.exceptions import BuildLockError # noqa from conda_build.os_utils import external # noqa -from .conda_interface import Dist # noqa -from .conda_interface import StringIO # noqa -from .conda_interface import cc_conda_build # noqa -from .conda_interface import context # noqa from .conda_interface import ( # noqa CondaHTTPError, + Dist, # noqa MatchSpec, + StringIO, # noqa TemporaryDirectory, VersionOrder, + cc_conda_build, # noqa + context, # noqa download, get_conda_channel, hashsum_file, diff --git a/pyproject.toml b/pyproject.toml index 93522bca6a..0257cb42c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -99,8 +99,7 @@ line-length = 180 # E, W = pycodestyle errors and warnings # F = pyflakes # I = isort -# D = pydocstyle -select = ["E", "W", "F", "I", "D1"] +select = ["E", "W", "F", "I"] # E402 module level import not at top of file # E722 do not use bare 'except' # E731 do not assign a lambda expression, use a def @@ -109,7 +108,6 @@ ignore = ["E402", "E722", "E731"] pydocstyle = {convention = "pep257"} [tool.pytest.ini_options] -minversion = 3.0 testpaths = ["tests"] norecursedirs = ["tests/test-recipes/*"] addopts = [ @@ -125,11 +123,13 @@ addopts = [ "--store-durations", "--strict-markers", "--tb=native", + "--xdoctest-modules", + "--xdoctest-style=google", "-vv", ] markers = [ - "serial: execute test serially (to avoid race conditions)", - "slow: execute the slow tests if active", - "sanity: execute the sanity tests", - "no_default_testing_config: used internally to disable monkeypatching for testing_config", + "serial: execute test serially (to avoid race conditions)", + "slow: execute the slow tests if active", + "sanity: execute the sanity tests", + "no_default_testing_config: used internally to disable monkeypatching for testing_config", ] diff --git a/tests/requirements-Linux.txt b/tests/requirements-Linux.txt new file mode 100644 index 0000000000..149ce09bad --- /dev/null +++ b/tests/requirements-Linux.txt @@ -0,0 +1,3 @@ +patch +patchelf +shellcheck diff --git a/tests/requirements-Windows.txt b/tests/requirements-Windows.txt new file mode 100644 index 0000000000..d08b4cac29 --- /dev/null +++ b/tests/requirements-Windows.txt @@ -0,0 +1,2 @@ +m2-git +m2-patch diff --git a/tests/requirements-linux.txt b/tests/requirements-linux.txt deleted file mode 100644 index cb3ae7e805..0000000000 --- a/tests/requirements-linux.txt +++ /dev/null @@ -1,5 +0,0 @@ -# conda-build supplemental test dependencies -# run as 'conda install -c defaults --file tests/requirements-linux.txt' -patch -patchelf -shellcheck diff --git a/tests/requirements-macOS.txt b/tests/requirements-macOS.txt new file mode 100644 index 0000000000..133b191333 --- /dev/null +++ b/tests/requirements-macOS.txt @@ -0,0 +1,2 @@ +patch +shellcheck diff --git a/tests/requirements-macos.txt b/tests/requirements-macos.txt deleted file mode 100644 index dbe8e3dd81..0000000000 --- a/tests/requirements-macos.txt +++ /dev/null @@ -1,4 +0,0 @@ -# conda-build supplemental test dependencies -# run as 'conda install -c defaults --file tests/requirements-macos.txt' -patch -shellcheck diff --git a/tests/requirements-windows.txt b/tests/requirements-windows.txt deleted file mode 100644 index 8d40d2482b..0000000000 --- a/tests/requirements-windows.txt +++ /dev/null @@ -1,4 +0,0 @@ -# conda-build supplemental test dependencies -# run as 'conda install -c defaults --file tests/requirements-windows.txt' -m2-git -m2-patch diff --git a/tests/requirements.txt b/tests/requirements.txt index b0ac07be77..02d34d6787 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,9 +1,8 @@ -# conda-build test dependencies -# run as 'conda install -c defaults --file tests/requirements.txt' anaconda-client beautifulsoup4 chardet conda >=4.13 +conda-forge::allure-pytest conda-index conda-package-handling conda-verify @@ -27,7 +26,6 @@ pytest-replay pytest-rerunfailures pytest-xdist python-libarchive-c -conda-forge::allure-pytest pytz requests ripgrep From d70520d0830a28a69af249f4b206a5b23752cadc Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 16:27:37 -0500 Subject: [PATCH 02/19] Update hash --- .github/workflows/tests.yml | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e1d1bfe073..0644e40b67 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -91,22 +91,21 @@ jobs: PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} - HASH: ${{ runner.os }}-${{ runner.arch }}-${{ matrix.default-channel }}-Py${{ matrix.python-version }}-${{ matrix.test-type }}-${{ matrix.test-group }} steps: - uses: actions/checkout@v3 with: fetch-depth: 0 - - name: Timestamp - run: echo "TIMESTAMP=$(date -u "+%Y%m")" >> $GITHUB_ENV + - name: Hash + Timestamp + run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - name: Cache conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ env.HASH }}-${{ env.TIMESTAMP }} + key: cache-${{ env.HASH }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 @@ -191,22 +190,21 @@ jobs: PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial and not slow' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} - HASH: ${{ runner.os }}-${{ runner.arch }}-${{ matrix.default-channel }}-Py${{ matrix.python-version }}-${{ matrix.test-type }}-${{ matrix.test-group }} steps: - uses: actions/checkout@v3 with: fetch-depth: 0 - - name: Timestamp - run: echo "TIMESTAMP=$(date -u "+%Y%m")" >> $GITHUB_ENV + - name: Hash + Timestamp + run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - name: Cache conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ env.HASH }}-${{ env.TIMESTAMP }} + key: cache-${{ env.HASH }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 @@ -304,15 +302,15 @@ jobs: with: fetch-depth: 0 - - name: Timestamp - run: echo "TIMESTAMP=$(date -u "+%Y%m")" >> $GITHUB_ENV + - name: Hash + Timestamp + run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - name: Cache conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir - key: ${{ env.HASH }}-${{ env.TIMESTAMP }} + key: cache-${{ env.HASH }} - name: Setup miniconda uses: conda-incubator/setup-miniconda@v2 From 8396f67a93f0a23b3449a06770e652ef63c3200b Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 16:53:53 -0500 Subject: [PATCH 03/19] Name every step & add test-report.xml --- .github/workflows/tests.yml | 134 ++++++++++++++++++++---------------- pyproject.toml | 2 +- 2 files changed, 75 insertions(+), 61 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0644e40b67..aae7795d7c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -93,7 +93,8 @@ jobs: PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} steps: - - uses: actions/checkout@v3 + - name: Checkout Source + uses: actions/checkout@v3 with: fetch-depth: 0 @@ -101,61 +102,65 @@ jobs: run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - - name: Cache conda + - name: Cache Conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir key: cache-${{ env.HASH }} - - name: Setup miniconda + - name: Setup Miniconda uses: conda-incubator/setup-miniconda@v2 with: condarc-file: .github/condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - - name: Setup environment + - name: Setup Environment run: | conda install --quiet --yes \ - --file ./tests/requirements.txt \ - --file ./tests/requirements-linux.txt \ + --file tests/requirements.txt \ + --file tests/requirements-linux.txt \ ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . - - name: Show info + - name: Show Info run: | conda info --verbose conda list --show-channel-urls - - name: Run tests + - name: Run Tests run: | pytest \ --alluredir="${{ env.ALLURE_DIR }}" \ --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ --cov=conda_build \ - --durations-path="./tools/durations/${{ runner.os }}.json" \ + --durations-path="tools/durations/${{ runner.os }}.json" \ --group=${{ matrix.test-group }} \ --splits=${{ env.PYTEST_SPLITS }} \ -n "${{ env.PYTEST_NUMPROCESSES }}" \ -m "${{ env.PYTEST_MARKER }}" - - uses: codecov/codecov-action@v3 + - name: Upload Coverage + uses: codecov/codecov-action@v3 with: flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} - - name: Upload durations + - name: Upload Test Results if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: durations-${{ env.HASH }} - path: ./tools/durations/${{ runner.os }}.json - retention-days: 7 # for durations.yml workflow - - - name: Tar Allure Results + name: test-results-${{ env.HASH }} + path: | + .coverage + tools/durations/${{ runner.os }}.json + test-report.xml + retention-days: 1 # temporary, combined in aggregate below + + - name: Tar Allure if: '!cancelled()' run: tar -zcf "${{ env.ALLURE_DIR }}.tar.gz" "${{ env.ALLURE_DIR }}" - - name: Upload Allure Results + - name: Upload Allure if: '!cancelled()' uses: actions/upload-artifact@v3 with: @@ -192,7 +197,8 @@ jobs: PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} steps: - - uses: actions/checkout@v3 + - name: Checkout Source + uses: actions/checkout@v3 with: fetch-depth: 0 @@ -200,65 +206,69 @@ jobs: run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - - name: Cache conda + - name: Cache Conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir key: cache-${{ env.HASH }} - - name: Setup miniconda + - name: Setup Miniconda uses: conda-incubator/setup-miniconda@v2 with: condarc-file: .github\condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - - name: Setup environment + - name: Setup Environment run: | choco install visualstudio2017-workload-vctools conda install --quiet --yes ` - --file .\tests\requirements.txt ` - --file .\tests\requirements-${{ runner.os }}.txt ` + --file tests\requirements.txt ` + --file tests\requirements-${{ runner.os }}.txt ` ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . - - name: Show info + - name: Show Info run: | conda info --verbose conda list --show-channel-urls - - name: Run tests + - name: Run Tests run: | pytest ` --alluredir="${{ env.ALLURE_DIR }}" ` --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" ` --cov=conda_build ` - --durations-path=".\tools\durations\${{ runner.os }}.json" ` + --durations-path="tools\durations\${{ runner.os }}.json" ` --group=${{ matrix.test-group }} ` --splits=${{ env.PYTEST_SPLITS }} ` -m "${{ env.PYTEST_MARKER }}" ` -n "${{ env.PYTEST_NUMPROCESSES }}" - - uses: codecov/codecov-action@v3 + - name: Upload Coverage + uses: codecov/codecov-action@v3 with: flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} - - name: Upload test results + - name: Upload Test Results if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: durations-${{ env.HASH }} - path: .\tools\durations\${{ runner.os }}.json - retention-days: 7 # for durations.yml workflow - - - name: Tar Allure Results + name: test-results-${{ env.HASH }} + path: | + .coverage + tools\durations\${{ runner.os }}.json + test-report.xml + retention-days: 1 # temporary, combined in aggregate below + + - name: Tar Allure if: '!cancelled()' run: tar -zcf "${{ env.ALLURE_DIR }}.tar.gz" "${{ env.ALLURE_DIR }}" # windows-2019/powershell ships with GNU tar 1.28 which struggles with Windows paths # window-2019/cmd ships with bsdtar 3.5.2 which doesn't have this problem shell: cmd - - name: Upload Allure Results + - name: Upload Allure if: '!cancelled()' uses: actions/upload-artifact@v3 with: @@ -298,7 +308,8 @@ jobs: PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} steps: - - uses: actions/checkout@v3 + - name: Checkout Source + uses: actions/checkout@v3 with: fetch-depth: 0 @@ -306,62 +317,66 @@ jobs: run: echo "HASH=${{ runner.os }}-${{ runner.arch }}-Py${{ matrix.python-version }}-${{ matrix.conda-version }}-${{ matrix.test-type }}-${{ matrix.test-group }}-$(date -u "+%Y%m")" >> $GITHUB_ENV shell: bash - - name: Cache conda + - name: Cache Conda uses: actions/cache@v3 with: path: ~/conda_pkgs_dir key: cache-${{ env.HASH }} - - name: Setup miniconda + - name: Setup Miniconda uses: conda-incubator/setup-miniconda@v2 with: condarc-file: .github/condarc python-version: ${{ matrix.python-version }} run-post: false # skip post cleanup - - name: Setup environment + - name: Setup Environment run: | sudo xcode-select --switch /Applications/Xcode_11.7.app conda install --quiet --yes \ - --file ./tests/requirements.txt \ - --file ./tests/requirements-${{ runner.os }}.txt \ + --file tests/requirements.txt \ + --file tests/requirements-${{ runner.os }}.txt \ ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . - - name: Show info + - name: Show Info run: | conda info --verbose conda list --show-channel-urls - - name: Run tests + - name: Run Tests run: | pytest \ --alluredir="${{ env.ALLURE_DIR }}" \ --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ --cov=conda_build \ - --durations-path=./tools/durations/${{ runner.os }}.json \ + --durations-path=tools/durations/${{ runner.os }}.json \ --group=${{ matrix.test-group }} \ --splits=${{ env.PYTEST_SPLITS }} \ -m "${{ env.PYTEST_MARKER }}" \ -n "${{ env.PYTEST_NUMPROCESSES }}" - - uses: codecov/codecov-action@v3 + - name: Upload Coverage + uses: codecov/codecov-action@v3 with: flags: ${{ runner.os }},${{ runner.arch }},${{ matrix.python-version }},${{ matrix.test-type }} - - name: Upload durations + - name: Upload Test Results if: '!cancelled()' uses: actions/upload-artifact@v3 with: - name: durations-${{ env.HASH }} - path: ./tools/durations/${{ runner.os }}.json - retention-days: 7 # for duration.yml workflow - - - name: Tar Allure Results + name: test-results-${{ env.HASH }} + path: | + .coverage + tools/durations/${{ runner.os }}.json + test-report.xml + retention-days: 1 # temporary, combined in aggregate below + + - name: Tar Allure if: '!cancelled()' run: tar -zcf "${{ env.ALLURE_DIR }}.tar.gz" "${{ env.ALLURE_DIR }}" - - name: Upload Allure Results + - name: Upload Allure if: '!cancelled()' uses: actions/upload-artifact@v3 with: @@ -381,22 +396,21 @@ jobs: runs-on: ubuntu-latest steps: - - name: Download test results + - name: Download Artifacts uses: actions/download-artifact@v3 - - name: Upload combined test results - # provides one downloadable archive of all .coverage/test-report.xml files - # of all matrix runs for further analysis. + - name: Upload Combined Test Results + # provides one downloadable archive of all matrix run test results for further analysis uses: actions/upload-artifact@v3 with: name: test-results-${{ github.sha }}-all - path: test-results-${{ github.sha }}-* - retention-days: 90 # default: 90 + path: test-results-* + retention-days: 7 # for durations.yml workflow - name: Test Summary uses: test-summary/action@v2 with: - paths: ./test-results-${{ github.sha }}-**/test-report*.xml + paths: test-results-*/test-report.xml # required check analyze: @@ -406,8 +420,8 @@ jobs: runs-on: ubuntu-latest steps: - - name: Decide whether the needed jobs succeeded or failed - uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe + - name: Determine Success + uses: re-actors/alls-green@v1.2.2 with: allowed-skips: ${{ toJSON(needs) }} jobs: ${{ toJSON(needs) }} diff --git a/pyproject.toml b/pyproject.toml index 0257cb42c7..06f1270176 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -118,7 +118,7 @@ addopts = [ "--cov-report=term-missing", "--cov-report=xml", "--durations=16", - "--junitxml=junit.xml", + "--junitxml=test-report.xml", "--splitting-algorithm=least_duration", "--store-durations", "--strict-markers", From 8215ad815ad512fe1269250d07ca2e4fcca34355 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 16:58:37 -0500 Subject: [PATCH 04/19] Go back to macos-11 --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index aae7795d7c..0da66e017b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -281,7 +281,7 @@ jobs: needs: changes if: github.event_name == 'schedule' || needs.changes.outputs.code == 'true' - runs-on: macos-latest + runs-on: macos-11 defaults: run: # https://github.com/conda-incubator/setup-miniconda#use-a-default-shell From 7ba7a7598609a9102cc0a1e6f6459a47ef7d9729 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:00:02 -0500 Subject: [PATCH 05/19] Update action version --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0da66e017b..6dcbaa258d 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -44,7 +44,7 @@ jobs: # https://github.com/marketplace/actions/paths-changes-filter#supported-workflows if: github.event_name != 'pull_request' - - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 + - uses: dorny/paths-filter@v2.11.1 id: filter with: filters: | From 266aa85ab63a47ffdba55755e6ea23e3910c95c2 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:01:34 -0500 Subject: [PATCH 06/19] Update requirements --- tests/requirements.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/requirements.txt b/tests/requirements.txt index 02d34d6787..ff9976c4d3 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -22,7 +22,6 @@ pytest pytest-cov pytest-forked pytest-mock -pytest-replay pytest-rerunfailures pytest-xdist python-libarchive-c From 9bceac065c1cfd548b7c9e0774f14e8af9a71fdf Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:04:15 -0500 Subject: [PATCH 07/19] Update tests.yml --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6dcbaa258d..e7a7994a07 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -119,7 +119,7 @@ jobs: run: | conda install --quiet --yes \ --file tests/requirements.txt \ - --file tests/requirements-linux.txt \ + --file tests/requirements-${{ runner.os }}.txt \ ${{ env.CONDA_CHANNEL_LABEL }}::conda pip install -e . From 9e26ee9c34e8dfca0d584f6e1f12e190f835e4ce Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:08:10 -0500 Subject: [PATCH 08/19] Update requirements.txt --- tests/requirements.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/requirements.txt b/tests/requirements.txt index ff9976c4d3..31a5ac757c 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -3,6 +3,8 @@ beautifulsoup4 chardet conda >=4.13 conda-forge::allure-pytest +conda-forge::pytest-split +conda-forge::pytest-xprocess conda-index conda-package-handling conda-verify From e89fd4a706dfdc8916c5195ae37c8366dce46d10 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:27:15 -0500 Subject: [PATCH 09/19] Update requirements.txt --- tests/requirements.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/requirements.txt b/tests/requirements.txt index 31a5ac757c..fbd694685c 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -5,6 +5,7 @@ conda >=4.13 conda-forge::allure-pytest conda-forge::pytest-split conda-forge::pytest-xprocess +conda-forge::xdoctest conda-index conda-package-handling conda-verify From 15ad3267254410a50a65234c91d794fffd654204 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:34:22 -0500 Subject: [PATCH 10/19] Update requirements.txt --- tests/requirements.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/requirements.txt b/tests/requirements.txt index fbd694685c..9ce7890a30 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,16 +1,15 @@ anaconda-client beautifulsoup4 chardet -conda >=4.13 +conda >=22.11.0 conda-forge::allure-pytest conda-forge::pytest-split conda-forge::pytest-xprocess conda-forge::xdoctest conda-index -conda-package-handling +conda-package-handling >=1.3 conda-verify contextlib2 -cytoolz filelock git jinja2 From 9a465eab36f09cd032615bc077723143cb69d27a Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Fri, 29 Sep 2023 17:35:58 -0500 Subject: [PATCH 11/19] Update tests.yml --- .github/workflows/tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e7a7994a07..3193b664c5 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -306,6 +306,7 @@ jobs: CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} steps: - name: Checkout Source From 44f7cb9f5bea896eb6a706bba2f86f9d96b91345 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Sat, 30 Sep 2023 09:13:29 -0500 Subject: [PATCH 12/19] Add empty duration files --- .github/workflows/durations.yml | 63 +++++++++++++++++++++++++++++++++ tools/durations/Linux.json | 1 + tools/durations/Windows.json | 1 + tools/durations/combine.py | 56 +++++++++++++++++++++++++++++ tools/durations/macOS.json | 1 + 5 files changed, 122 insertions(+) create mode 100644 .github/workflows/durations.yml create mode 100644 tools/durations/Linux.json create mode 100644 tools/durations/Windows.json create mode 100644 tools/durations/combine.py create mode 100644 tools/durations/macOS.json diff --git a/.github/workflows/durations.yml b/.github/workflows/durations.yml new file mode 100644 index 0000000000..d296d4c3e7 --- /dev/null +++ b/.github/workflows/durations.yml @@ -0,0 +1,63 @@ +name: Update Durations + +on: + # every Sunday at 00:00 UTC + # https://crontab.guru/#0_0_*_*_0 + schedule: + - cron: '0 0 * * 0' + + # https://docs.github.com/en/webhooks-and-events/webhooks/webhook-events-and-payloads#workflow_dispatch + workflow_dispatch: + +jobs: + update-durations: + runs-on: ubuntu-latest + permissions: + # necessary to open PR + # https://github.com/peter-evans/create-pull-request#action-inputs + contents: write + pull-requests: write + steps: + - uses: actions/checkout@v3 + + - name: download recent artifacts + run: | + gh run list \ + --branch main \ + --workflow tests \ + --limit 10 \ + --json databaseId \ + --jq '.[].databaseId' \ + | xargs \ + -n 1 \ + gh run download \ + --dir ${{ runner.temp }}/artifacts/ \ + --pattern '*-all' \ + || true + env: + GITHUB_TOKEN: ${{ github.token }} + + - uses: actions/setup-python@v4 + with: + python-version: '3.11' + + - name: combine recent durations from artifacts + run: python ./tools/durations/combine.py ${{ runner.temp }}/artifacts/ + + - name: create updated durations PR + uses: peter-evans/create-pull-request@v5 + with: + push-to-fork: conda-bot/conda + token: ${{ secrets.DURATIONS_TOKEN }} + branch: update-durations + delete-branch: true + commit-message: Update test durations + author: Conda Bot <18747875+conda-bot@users.noreply.github.com> + committer: Conda Bot <18747875+conda-bot@users.noreply.github.com> + title: 🤖 Update test durations + body: | + Aggregate recent test durations for each test and update the durations file. + + [durations.yml]: ${{ github.server_url }}/${{ github.repository }}/blob/main/.github/workflows/durations.yml + + This PR was created automatically by the [`durations.yml`][durations.yml] workflow. diff --git a/tools/durations/Linux.json b/tools/durations/Linux.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/tools/durations/Linux.json @@ -0,0 +1 @@ +{} diff --git a/tools/durations/Windows.json b/tools/durations/Windows.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/tools/durations/Windows.json @@ -0,0 +1 @@ +{} diff --git a/tools/durations/combine.py b/tools/durations/combine.py new file mode 100644 index 0000000000..b42de633fe --- /dev/null +++ b/tools/durations/combine.py @@ -0,0 +1,56 @@ +# Copyright (C) 2014 Anaconda, Inc +# SPDX-License-Identifier: BSD-3-Clause +""" +Script to combine test durations from all runs. + +If the tests splits are looking uneven or the test suite has +siginificantly changed, update ./tools/durations/${OS}.json in the root of the +repository and pytest-split may work better. + +``` +$ gh run list --branch +$ gh run download --dir ./artifacts/ +$ python ./tools/durations/combine.py ./artifacts/ +$ git add ./tools/durations/ +$ git commit -m "Update test durations" +$ git push +``` +""" +import json +from pathlib import Path +from statistics import fmean +from sys import argv + +combined: dict[str, dict[str, list[float]]] = {} + +durations_dir = Path(__file__).parent +artifacts_dir = Path(argv[-1]).expanduser().resolve() + +# aggregate all new durations +for path in artifacts_dir.glob("**/*.json"): + os = path.stem + combined_os = combined.setdefault(os, {}) + + data = json.loads(path.read_text()) + for key, value in data.items(): + combined_os.setdefault(key, []).append(value) + +# aggregate new and old durations while discarding durations that no longer exist +for path in durations_dir.glob("**/*.json"): + os = path.stem + combined_os = combined.setdefault(os, {}) + + data = json.loads(path.read_text()) + for key in set(combined_os).intersection(durations_dir.glob("**/*.json")): + combined_os.setdefault(key, []).append(data[key]) + +# write out averaged durations +for os, combined_os in combined.items(): + (durations_dir / f"{os}.json").write_text( + json.dumps( + {key: fmean(values) for key, values in combined_os.items()}, + indent=4, + sort_keys=True, + ) + + "\n" # include trailing newline + ) diff --git a/tools/durations/macOS.json b/tools/durations/macOS.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/tools/durations/macOS.json @@ -0,0 +1 @@ +{} From fdc248e1023dbafad873931c1daf075f3d3a1151 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Sat, 30 Sep 2023 10:49:00 -0500 Subject: [PATCH 13/19] YAML multiline string --- .github/workflows/tests.yml | 84 ++++++++++++++++++------------------- 1 file changed, 42 insertions(+), 42 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 3193b664c5..0a3e24dd73 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -116,12 +116,12 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: | - conda install --quiet --yes \ - --file tests/requirements.txt \ - --file tests/requirements-${{ runner.os }}.txt \ + run: >- + conda install --quiet --yes + --file tests/requirements.txt + --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - pip install -e . + && pip install -e . - name: Show Info run: | @@ -129,15 +129,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: | - pytest \ - --alluredir="${{ env.ALLURE_DIR }}" \ - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ - --cov=conda_build \ - --durations-path="tools/durations/${{ runner.os }}.json" \ - --group=${{ matrix.test-group }} \ - --splits=${{ env.PYTEST_SPLITS }} \ - -n "${{ env.PYTEST_NUMPROCESSES }}" \ + run: >- + pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" + --cov=conda_build + --durations-path="tools/durations/${{ runner.os }}.json" + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -n "${{ env.PYTEST_NUMPROCESSES }}" -m "${{ env.PYTEST_MARKER }}" - name: Upload Coverage @@ -220,13 +220,13 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: | + run: >- choco install visualstudio2017-workload-vctools - conda install --quiet --yes ` - --file tests\requirements.txt ` - --file tests\requirements-${{ runner.os }}.txt ` + && conda install --quiet --yes + --file tests\requirements.txt + --file tests\requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - pip install -e . + && pip install -e . - name: Show Info run: | @@ -234,15 +234,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: | - pytest ` - --alluredir="${{ env.ALLURE_DIR }}" ` - --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" ` - --cov=conda_build ` - --durations-path="tools\durations\${{ runner.os }}.json" ` - --group=${{ matrix.test-group }} ` - --splits=${{ env.PYTEST_SPLITS }} ` - -m "${{ env.PYTEST_MARKER }}" ` + run: >- + pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" + --cov=conda_build + --durations-path="tools\durations\${{ runner.os }}.json" + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -m "${{ env.PYTEST_MARKER }}" -n "${{ env.PYTEST_NUMPROCESSES }}" - name: Upload Coverage @@ -332,13 +332,13 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: | + run: >- sudo xcode-select --switch /Applications/Xcode_11.7.app - conda install --quiet --yes \ - --file tests/requirements.txt \ - --file tests/requirements-${{ runner.os }}.txt \ + && conda install --quiet --yes + --file tests/requirements.txt + --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - pip install -e . + && pip install -e . - name: Show Info run: | @@ -346,15 +346,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: | - pytest \ - --alluredir="${{ env.ALLURE_DIR }}" \ - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" \ - --cov=conda_build \ - --durations-path=tools/durations/${{ runner.os }}.json \ - --group=${{ matrix.test-group }} \ - --splits=${{ env.PYTEST_SPLITS }} \ - -m "${{ env.PYTEST_MARKER }}" \ + run: >- + pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" + --cov=conda_build + --durations-path=tools/durations/${{ runner.os }}.json + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -m "${{ env.PYTEST_MARKER }}" -n "${{ env.PYTEST_NUMPROCESSES }}" - name: Upload Coverage From 13293d950d59416a559fd478a530a66465522f2b Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Sat, 30 Sep 2023 10:55:11 -0500 Subject: [PATCH 14/19] Remove YAML multiline chomping --- .github/workflows/tests.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0a3e24dd73..4dbbf9b965 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -116,7 +116,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: >- + run: > conda install --quiet --yes --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt @@ -129,7 +129,7 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: >- + run: > pytest --alluredir="${{ env.ALLURE_DIR }}" --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" @@ -220,7 +220,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: >- + run: > choco install visualstudio2017-workload-vctools && conda install --quiet --yes --file tests\requirements.txt @@ -234,7 +234,7 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: >- + run: > pytest --alluredir="${{ env.ALLURE_DIR }}" --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" @@ -332,7 +332,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: >- + run: > sudo xcode-select --switch /Applications/Xcode_11.7.app && conda install --quiet --yes --file tests/requirements.txt @@ -346,7 +346,7 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: >- + run: > pytest --alluredir="${{ env.ALLURE_DIR }}" --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" From ed8f77134b50b149c507004b9b29acfa8a56877e Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Sat, 30 Sep 2023 11:06:45 -0500 Subject: [PATCH 15/19] YAML flow scalars --- .github/workflows/tests.yml | 66 +++++++++++++++++-------------------- 1 file changed, 30 insertions(+), 36 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4dbbf9b965..e11b95ecf4 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -116,8 +116,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: > - conda install --quiet --yes + run: conda install --quiet --yes --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda @@ -129,16 +128,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: > - pytest - --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" - --cov=conda_build - --durations-path="tools/durations/${{ runner.os }}.json" - --group=${{ matrix.test-group }} - --splits=${{ env.PYTEST_SPLITS }} - -n "${{ env.PYTEST_NUMPROCESSES }}" - -m "${{ env.PYTEST_MARKER }}" + run: pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" + --cov=conda_build + --durations-path="tools/durations/${{ runner.os }}.json" + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -n "${{ env.PYTEST_NUMPROCESSES }}" + -m "${{ env.PYTEST_MARKER }}" - name: Upload Coverage uses: codecov/codecov-action@v3 @@ -220,8 +218,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: > - choco install visualstudio2017-workload-vctools + run: choco install visualstudio2017-workload-vctools && conda install --quiet --yes --file tests\requirements.txt --file tests\requirements-${{ runner.os }}.txt @@ -234,16 +231,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: > - pytest - --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" - --cov=conda_build - --durations-path="tools\durations\${{ runner.os }}.json" - --group=${{ matrix.test-group }} - --splits=${{ env.PYTEST_SPLITS }} - -m "${{ env.PYTEST_MARKER }}" - -n "${{ env.PYTEST_NUMPROCESSES }}" + run: pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" + --cov=conda_build + --durations-path="tools\durations\${{ runner.os }}.json" + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -m "${{ env.PYTEST_MARKER }}" + -n "${{ env.PYTEST_NUMPROCESSES }}" - name: Upload Coverage uses: codecov/codecov-action@v3 @@ -332,8 +328,7 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: > - sudo xcode-select --switch /Applications/Xcode_11.7.app + run: sudo xcode-select --switch /Applications/Xcode_11.7.app && conda install --quiet --yes --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt @@ -346,16 +341,15 @@ jobs: conda list --show-channel-urls - name: Run Tests - run: > - pytest - --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" - --cov=conda_build - --durations-path=tools/durations/${{ runner.os }}.json - --group=${{ matrix.test-group }} - --splits=${{ env.PYTEST_SPLITS }} - -m "${{ env.PYTEST_MARKER }}" - -n "${{ env.PYTEST_NUMPROCESSES }}" + run: pytest + --alluredir="${{ env.ALLURE_DIR }}" + --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" + --cov=conda_build + --durations-path=tools/durations/${{ runner.os }}.json + --group=${{ matrix.test-group }} + --splits=${{ env.PYTEST_SPLITS }} + -m "${{ env.PYTEST_MARKER }}" + -n "${{ env.PYTEST_NUMPROCESSES }}" - name: Upload Coverage uses: codecov/codecov-action@v3 From dd2734dbc09ed6b5581c6636a9204a21d6ebddbe Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Mon, 2 Oct 2023 15:11:26 -0500 Subject: [PATCH 16/19] Update versions --- .github/workflows/tests.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e11b95ecf4..f5a76e79ff 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -39,7 +39,7 @@ jobs: outputs: code: ${{ steps.filter.outputs.code }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 # dorny/paths-filter needs git clone for non-PR events # https://github.com/marketplace/actions/paths-changes-filter#supported-workflows if: github.event_name != 'pull_request' @@ -94,7 +94,7 @@ jobs: steps: - name: Checkout Source - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 @@ -116,7 +116,8 @@ jobs: run-post: false # skip post cleanup - name: Setup Environment - run: conda install --quiet --yes + run: conda install + --quiet --yes --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda @@ -196,7 +197,7 @@ jobs: steps: - name: Checkout Source - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 @@ -219,7 +220,8 @@ jobs: - name: Setup Environment run: choco install visualstudio2017-workload-vctools - && conda install --quiet --yes + && conda install + --quiet --yes --file tests\requirements.txt --file tests\requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda @@ -306,7 +308,7 @@ jobs: steps: - name: Checkout Source - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 0 @@ -329,7 +331,8 @@ jobs: - name: Setup Environment run: sudo xcode-select --switch /Applications/Xcode_11.7.app - && conda install --quiet --yes + && conda install + --quiet --yes --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda @@ -418,6 +421,7 @@ jobs: - name: Determine Success uses: re-actors/alls-green@v1.2.2 with: + # permit jobs to be skipped if there are no code changes (see changes job) allowed-skips: ${{ toJSON(needs) }} jobs: ${{ toJSON(needs) }} @@ -450,7 +454,7 @@ jobs: steps: # Clean checkout of specific git ref needed for package metadata version # which needs env vars GIT_DESCRIBE_TAG and GIT_BUILD_STR: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ github.ref }} clean: true From d9ee69f2b2ba672dac141caa4d19ef647f66c1ec Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Mon, 2 Oct 2023 15:18:30 -0500 Subject: [PATCH 17/19] Ensure strings --- .github/workflows/tests.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f5a76e79ff..dbbf613063 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -89,8 +89,8 @@ jobs: ALLURE_DIR: ${{ github.workspace }}/allure-results CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} - PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} - PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} + PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && '0' || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && '2' || '3' }} steps: - name: Checkout Source @@ -192,8 +192,8 @@ jobs: ALLURE_DIR: ${{ github.workspace }}\allure-results CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial and not slow' }} - PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} - PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} + PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && '0' || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && '2' || '3' }} steps: - name: Checkout Source @@ -303,8 +303,8 @@ jobs: ALLURE_DIR: ${{ github.workspace }}/allure-results CONDA_CHANNEL_LABEL: ${{ matrix.conda-version == 'canary' && 'conda-canary/label/dev' || 'defaults' }} PYTEST_MARKER: ${{ matrix.test-type == 'serial' && 'serial' || 'not serial' }} - PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && 0 || 'auto' }} - PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && 2 || 3 }} + PYTEST_NUMPROCESSES: ${{ matrix.test-type == 'serial' && '0' || 'auto' }} + PYTEST_SPLITS: ${{ matrix.test-type == 'serial' && '2' || '3' }} steps: - name: Checkout Source From dff6230b29920b5a50f23f98497758467e28f04e Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Mon, 2 Oct 2023 15:26:37 -0500 Subject: [PATCH 18/19] Remove pip install --- .github/workflows/tests.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index dbbf613063..d05d986935 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -121,7 +121,6 @@ jobs: --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - && pip install -e . - name: Show Info run: | @@ -225,7 +224,6 @@ jobs: --file tests\requirements.txt --file tests\requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - && pip install -e . - name: Show Info run: | @@ -336,7 +334,6 @@ jobs: --file tests/requirements.txt --file tests/requirements-${{ runner.os }}.txt ${{ env.CONDA_CHANNEL_LABEL }}::conda - && pip install -e . - name: Show Info run: | From 102eee18dc7add06d79d62695bf7dbdc952cc959 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Mon, 2 Oct 2023 15:32:53 -0500 Subject: [PATCH 19/19] Remove --basetemp --- .github/workflows/tests.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d05d986935..f69826295e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -130,7 +130,6 @@ jobs: - name: Run Tests run: pytest --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" --cov=conda_build --durations-path="tools/durations/${{ runner.os }}.json" --group=${{ matrix.test-group }} @@ -233,7 +232,6 @@ jobs: - name: Run Tests run: pytest --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}\${{ matrix.test-type }}" --cov=conda_build --durations-path="tools\durations\${{ runner.os }}.json" --group=${{ matrix.test-group }} @@ -343,7 +341,6 @@ jobs: - name: Run Tests run: pytest --alluredir="${{ env.ALLURE_DIR }}" - --basetemp="${{ runner.temp }}/${{ matrix.test-type }}" --cov=conda_build --durations-path=tools/durations/${{ runner.os }}.json --group=${{ matrix.test-group }}