From 75148002325950f43a6753dcea5f3614210aefca Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 4 Aug 2026 22:10:31 +0000 Subject: [PATCH 1/2] Initial plan From e32230e171face4d9aebbf9c3bff4fdc50775ab5 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 4 Aug 2026 22:13:23 +0000 Subject: [PATCH 2/2] Fix update-citations: NameError, git add failure, and timeout Co-authored-by: Arthod <32404077+Arthod@users.noreply.github.com> --- .github/workflows/update-citations.yml | 6 +++++- bin/update_scholar_citations.py | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/update-citations.yml b/.github/workflows/update-citations.yml index 8a2428d..80d51ba 100644 --- a/.github/workflows/update-citations.yml +++ b/.github/workflows/update-citations.yml @@ -49,7 +49,7 @@ jobs: set +e echo "🚀 Running citation update script (single attempt)..." start_time=$(date) - timeout 90 python bin/update_scholar_citations.py + timeout 300 python bin/update_scholar_citations.py status=$? end_time=$(date) if [ $status -eq 0 ]; then @@ -93,6 +93,10 @@ jobs: - name: Commit and push if changed run: | + if [ ! -f _data/citations.yml ]; then + echo "â„šī¸ No citations.yml file to commit." + exit 0 + fi git add _data/citations.yml git diff --staged --quiet || ( echo "📤 Committing and pushing changes..." diff --git a/bin/update_scholar_citations.py b/bin/update_scholar_citations.py index 1c4f57c..f229587 100644 --- a/bin/update_scholar_citations.py +++ b/bin/update_scholar_citations.py @@ -42,6 +42,7 @@ def get_scholar_citations() -> None: today = datetime.now().strftime("%Y-%m-%d") # Check if the output file was already updated today + existing_data = None if os.path.exists(OUTPUT_FILE): try: with open(OUTPUT_FILE, "r") as f: @@ -62,7 +63,7 @@ def get_scholar_citations() -> None: citation_data = {"metadata": {"last_updated": today}, "papers": {}} - scholarly.set_timeout(15) + scholarly.set_timeout(30) scholarly.set_retries(3) try: author = scholarly.search_author_id(SCHOLAR_USER_ID)