Fix refresh-elo cwd bug: use a subshell instead of && cd chain

If refresh_elo.py failed, the trailing '&& cd ../../..' never ran,
leaving the job's shell inside statcheck-elo-scraper/ for the
subsequent git commands — which then tried to add a doubly-nested,
nonexistent path and failed with a confusing pathspec error instead
of the real failure. A subshell scopes the cd regardless of the
script's exit status.

Found by manually triggering the new project's ELO-refresh schedule:
the underlying scraper is currently failing on its own (OneDrive
source URL now 404s) — that's a separate, pre-existing data-source
issue outside this repo, not something this commit addresses.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SBzcNkW7JcYipnAX6HfgmK
This commit is contained in:
2026-09-04 15:35:38 -05:00
co-authored by Claude Sonnet 5
parent ababea0b1b
commit 5db0fb4839
+1 -1
View File
@@ -65,7 +65,7 @@ refresh-elo:
variables:
GIT_STRATEGY: clone
script:
- cd sites/40k-rankings/statcheck-elo-scraper && python refresh_elo.py && cd ../../..
- (cd sites/40k-rankings/statcheck-elo-scraper && python refresh_elo.py)
- git config user.email "gitlab-ci@gateway-gamers.net"
- git config user.name "GitLab CI"
- git remote set-url origin "https://oauth2:${GITLAB_ACCESS_TOKEN}@${CI_SERVER_HOST}/${CI_PROJECT_PATH}.git"