diff --git a/.github/actions/install_requirements/action.yml b/.github/actions/install_requirements/action.yml index 614ce70..958bea5 100644 --- a/.github/actions/install_requirements/action.yml +++ b/.github/actions/install_requirements/action.yml @@ -29,10 +29,10 @@ runs: - name: Create lockfile run: | - mkdir -p lockfiles-${{ inputs.python_version }} - pip freeze --exclude-editable > lockfiles-${{ inputs.python_version }}/${{ inputs.requirements_file }} + mkdir -p lockfiles + pip freeze --exclude-editable > lockfiles/${{ inputs.requirements_file }} # delete the self referencing line and make sure it isn't blank - sed -i'' -e '/file:/d' lockfiles-${{ inputs.python_version }}/${{ inputs.requirements_file }} + sed -i'' -e '/file:/d' lockfiles/${{ inputs.requirements_file }} shell: bash - name: Upload lockfiles @@ -49,7 +49,7 @@ runs: - name: If requirements file exists, check it matches pip installed packages run: | if [ -s ${{ inputs.requirements_file }} ]; then - if ! diff -u ${{ inputs.requirements_file }} lockfiles-${{ inputs.python_version }}/${{ inputs.requirements_file }}; then + if ! diff -u ${{ inputs.requirements_file }} lockfiles/${{ inputs.requirements_file }}; then echo "Error: ${{ inputs.requirements_file }} need the above changes to be exhaustive" exit 1 fi diff --git a/.github/workflows/code.yml b/.github/workflows/code.yml index 2584562..716b8d0 100644 --- a/.github/workflows/code.yml +++ b/.github/workflows/code.yml @@ -104,12 +104,20 @@ jobs: HAS_PYPI_TOKEN: ${{ secrets.PYPI_TOKEN != '' }} steps: - - uses: actions/download-artifact@v4 + - name: Download dist + uses: actions/download-artifact@v4 with: pattern: dist* path: dist merge-multiple: true + - name: Download lockfiles + uses: actions/download-artifact@v4 + with: + pattern: lockfiles* + path: lockfiles + merge-multiple: true + - name: Fixup blank lockfiles # Github release artifacts can't be blank run: for f in lockfiles/*; do [ -s $f ] || echo '# No requirements' >> $f; done