Skip to content

Commit 57cb8c0

Browse files
authored
Fix CI cancellation on GitHub runners by adding swap space (#82)
* Add swap space setup in PR evaluation workflow, fixed "--active" in process_pr_submission * apply ruff formatting fixes * changed self-hosted to ubuntu-latest * renamed swapfile to avoid conflict
1 parent 84c9e8a commit 57cb8c0

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

.github/workflows/pr-evaluation.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
github.event.comment.author_association == 'COLLABORATOR' ||
1616
github.event.comment.user.login == github.event.issue.user.login
1717
)
18-
runs-on: self-hosted
18+
runs-on: ubuntu-latest
1919
permissions:
2020
checks: write
2121
contents: read
@@ -207,6 +207,15 @@ jobs:
207207
"base/router_inference/predictions/${ROUTER_NAME}-robustness.json"
208208
echo "Copied prediction file from PR to base workspace"
209209
210+
- name: Enable Swap Space
211+
run: |
212+
# Create a new 10GB swap file (using a unique name to avoid conflicts)
213+
sudo fallocate -l 10G /swapfile10g
214+
sudo chmod 600 /swapfile10g
215+
sudo mkswap /swapfile10g
216+
sudo swapon /swapfile10g
217+
sudo swapon --show
218+
210219
- name: Evaluate submission
211220
if: ${{ steps.detect.outputs.router != '' }}
212221
id: evaluate

automation/process_pr_submission.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ def main(argv: Optional[list[str]] = None) -> int:
459459
validation_cmd = [
460460
"uv",
461461
"run",
462-
"python",
462+
"--activepython",
463463
"router_inference/check_config_prediction_files.py",
464464
args.router,
465465
args.split,
@@ -470,7 +470,7 @@ def main(argv: Optional[list[str]] = None) -> int:
470470
evaluation_cmd = [
471471
"uv",
472472
"run",
473-
"python",
473+
"--activepython",
474474
"llm_evaluation/run.py",
475475
args.router,
476476
args.split,

0 commit comments

Comments
 (0)