From 07c2425c1419e919a203f9cd6d4e0ce1ee4f863e Mon Sep 17 00:00:00 2001 From: Atharva Arya Date: Tue, 24 Nov 2026 17:44:39 +0530 Subject: [PATCH] Pin doi2cff and nameparser in the citation job doi2cff fails to import HumanName from nameparser 3. Fail the citation step when every doi2cff attempt fails. --- .github/workflows/post-release.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/post-release.yml b/.github/workflows/post-release.yml index 020ba295b6c..620fc1a3876 100644 --- a/.github/workflows/post-release.yml +++ b/.github/workflows/post-release.yml @@ -56,19 +56,19 @@ jobs: python-version: "3.x" - name: Install doi2cff - run: pip install git+https://github.com/citation-file-format/doi2cff + # doi2cff is unmaintained and breaks on nameparser 3 (HumanName import) + run: pip install "git+https://github.com/citation-file-format/doi2cff@8e2d45650b8ee0cbe5a6e957e1d48a1d86c35c60" "nameparser<3" - name: Update CITATION.cff run: | rm -f CITATION.cff - max_attempts=10 - attempt=1 - until doi2cff init 10.5281/zenodo.592480 || [ $attempt -eq $max_attempts ]; do + for attempt in $(seq 10); do + doi2cff init 10.5281/zenodo.592480 && exit 0 echo "Attempt $attempt failed. Retrying in 60 seconds..." rm -f CITATION.cff sleep 60 - attempt=$((attempt + 1)) done + exit 1 - uses: actions/upload-artifact@v7 with: