@@ -45,25 +45,29 @@ runs:
4545 - name : Set up Poetry (${{ inputs.poetry-version }})
4646 shell : bash
4747 run : |
48- wget --https-only -O - https://install.python-poetry.org | POETRY_VERSION="${{ inputs.poetry-version }}" "$PYTHON_BINARY" /tmp/install_poetry.py
48+ wget --https-only -O - https://install.python-poetry.org | POETRY_VERSION="${{ inputs.poetry-version }}" "$PYTHON_BINARY" -
4949 echo "$HOME/.local/bin" >> $GITHUB_PATH
5050 env :
5151 PYTHON_BINARY : " python${{ inputs.python-version }}"
5252
53- - name : Find Poetry environment path
54- id : poetry-env-path
53+ - name : Setup cache variables
54+ id : setup-cache-variables
5555 shell : bash
5656 run : |
57+ echo "ImageOS=$ImageOS"
58+ echo "ImageVersion=$ImageVersion"
5759 POETRY_ENV_PATH=$(poetry config virtualenvs.path)
5860 echo "POETRY_ENV_PATH=$POETRY_ENV_PATH" >> $GITHUB_OUTPUT
61+ echo "IMAGE_OS=$ImageOS" >> $GITHUB_OUTPUT
62+ echo "IMAGE_VERSION=$ImageVersion" >> $GITHUB_OUTPUT
5963
6064 - name : Cache Poetry environment
6165 if : inputs.use-cache == 'true'
6266 id : cache-poetry-env
6367 uses : actions/cache@v4
6468 with :
65- path : ${{ steps.poetry-env-path .outputs.POETRY_ENV_PATH }}
66- key : poetry-env-${{ runner.os }}-${{ runner.os }}-${{ runner.name }}-${{ inputs.poetry-version }}-${{ inputs.python-version }}-${{ inputs.extras }}
69+ path : ${{ steps.setup-cache-variables .outputs.POETRY_ENV_PATH }}
70+ key : poetry-env-${{ steps.setup-cache-variables.outputs.IMAGE_OS }}-${{ steps.setup-cache-variables.outputs.IMAGE_VERSION }}-${{ inputs.poetry-version }}-${{ inputs.python-version }}-${{ inputs.extras }}
6771
6872 - name : Poetry install with extras
6973 if : inputs.use-cache != 'true' || steps.cache-poetry-env.outputs.cache-hit != 'true'
0 commit comments