diff --git a/.github/workflows/build-deps-ci-action.yml b/.github/workflows/build-deps-ci-action.yml index e584bf9c1d50..2ebd8b77cacf 100644 --- a/.github/workflows/build-deps-ci-action.yml +++ b/.github/workflows/build-deps-ci-action.yml @@ -276,6 +276,7 @@ jobs: if: ${{ inputs.kind == 'windows' }} env: USE_S3_CACHE: 'false' + GITHUB_WORKSPACE: 'C:\Windows\Temp\testing' timeout-minutes: 90 strategy: fail-fast: false @@ -312,6 +313,7 @@ jobs: python3 -c "import os; os.makedirs('artifacts', exist_ok=True)" cd artifacts tar xvf ${{ inputs.package-name }}-${{ inputs.salt-version }}-onedir-windows-${{ matrix.arch }}.tar.xz + - name: Set up Python ${{ inputs.python-version }} if: steps.nox-dependencies-cache.outputs.cache-hit != 'true' uses: actions/setup-python@v5 diff --git a/.github/workflows/test-packages-action-windows.yml b/.github/workflows/test-packages-action-windows.yml index c13aa143f689..f239e158994a 100644 --- a/.github/workflows/test-packages-action-windows.yml +++ b/.github/workflows/test-packages-action-windows.yml @@ -117,11 +117,17 @@ jobs: steps: + - name: Set up Python ${{ inputs.python-version }} + uses: actions/setup-python@v5 + with: + python-version: "${{ inputs.python-version }}" + - name: "Throttle Builds" shell: bash run: | t=$(python3 -c 'import random, sys; sys.stdout.write(str(random.randint(1, 15)))'); echo "Sleeping $t seconds"; sleep "$t" + - name: "Set `TIMESTAMP` environment variable" shell: bash run: | @@ -134,24 +140,13 @@ jobs: uses: actions/download-artifact@v4 with: name: ${{ inputs.package-name }}-${{ inputs.salt-version }}-${{ inputs.arch }}-${{ inputs.pkg-type }} - path: artifacts/pkg/ + path: ./artifacts/pkg/ - name: Download Onedir Tarball as an Artifact uses: actions/download-artifact@v4 with: name: ${{ inputs.package-name }}-${{ inputs.salt-version }}-onedir-${{ inputs.platform }}-${{ inputs.arch }}.tar.xz - path: artifacts/ - - - name: Set up Python ${{ inputs.python-version }} - uses: actions/setup-python@v5 - with: - python-version: "${{ inputs.python-version }}" - - - name: Install Nox - run: | - python3 -m pip install 'nox==${{ inputs.nox-version }}' - env: - PIP_INDEX_URL: https://pypi.org/simple + path: ./artifacts/ - name: Decompress Onedir Tarball shell: bash @@ -160,9 +155,13 @@ jobs: cd artifacts tar xvf ${{ inputs.package-name }}-${{ inputs.salt-version }}-onedir-${{ inputs.platform }}-${{ inputs.arch }}.tar.xz - - name: List Packages + - name: Install Nox run: | - tree artifacts/pkg/ + python3 -m pip install 'nox==${{ inputs.nox-version }}' + env: + PIP_INDEX_URL: https://pypi.org/simple + + - run: python3 --version - name: Download nox.windows.${{ inputs.arch }}.tar.* artifact for session ${{ inputs.nox-session }} uses: actions/download-artifact@v4 @@ -173,25 +172,30 @@ jobs: run: | nox --force-color -e decompress-dependencies -- windows ${{ inputs.arch }} - - name: Rename salt directory - run: ren ./salt ./salt-bak + - name: Find and remove pyc files + shell: bash + run: | + find . -name '*.pyc' -delete + find .nox -name '*.pyc' -delete + + - name: List Packages + run: | + dir . + dir artifacts/ + dir artifacts/pkg + dir .nox/ci-test-onedir + + - name: Check nox python + continue-on-error: true + run: '.nox\ci-test-onedir\Scripts\python.exe' --version - name: Show System Info env: SKIP_REQUIREMENTS_INSTALL: "1" - PRINT_TEST_SELECTION: "0" - PRINT_TEST_PLAN_ONLY: "0" - PRINT_SYSTEM_INFO_ONLY: "1" - SKIP_INITIAL_ONEDIR_FAILURES: "1" - SKIP_INITIAL_GH_ACTIONS_FAILURES: "1" SKIP_CODE_COVERAGE: "1" - OUTPUT_COLUMNS: "190" - GITHUB_ACTIONS_PIPELINE: "1" - RAISE_DEPRECATIONS_RUNTIME_ERRORS: "1" - TOOLS_DISTRO_SLUG: "${{ inputs.distro-slug }}" PYTHONUTF8: "1" run: | - nox --force-color -f noxfile.py -e "${{ inputs.nox-session }}-pkgs" -- '${{ matrix.tests-chunk }}' + nox --force-color -f noxfile.py -e "${{ inputs.nox-session }}-pkgs" -- '${{ matrix.tests-chunk }}' --log-cli-level=debug - name: Run Package Tests env: