Skip to content

Commit 1a000da

Browse files
authored
Add mask for PyPI API token (#35863)
Add mask for PyPI API token
2 parents 901058b + 726c96e commit 1a000da

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

.github/workflows/finalize_release.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,10 @@ jobs:
9393
echo "::add-mask::$PYPI_PASSWORD"
9494
- name: Validate PyPi id/password
9595
run: |
96-
echo "::add-mask::${{ github.event.inputs.PYPI_API_TOKEN }}"
97-
if [ "${{ github.event.inputs.PYPI_API_TOKEN }}" == "" ]
96+
# Workaround for Actions bug - https://github.com/actions/runner/issues/643
97+
PYPI_API_TOKEN=$(jq -r '.inputs.PYPI_API_TOKEN' $GITHUB_EVENT_PATH)
98+
echo "::add-mask::$PYPI_API_TOKEN"
99+
if [ "$PYPI_API_TOKEN" == "" ]
98100
then
99101
echo "Must provide a PyPi password to publish artifacts to PyPi"
100102
exit 1

0 commit comments

Comments
 (0)