Skip to content

Commit 3e67f32

Browse files
Revert projects-per-job to 4 and restore target/ cleanup
Keeping target/ between Anchor projects backfired — each project has its own Cargo workspace so the build cache from one doesn't help the next, and the accumulated artifacts slow down subsequent builds. Anchor wall clock went from 18 min to 34 min. Reverting MIN_PROJECTS_PER_JOB back to 4 (more parallel jobs with less work each = faster wall clock) and restoring rm -rf target cleanup. The cargo registry cache (actions/cache) is still in place — that caches downloaded crate tarballs which ARE shared across projects.
1 parent 1ef2cbe commit 3e67f32

4 files changed

Lines changed: 7 additions & 6 deletions

File tree

.github/workflows/anchor.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ concurrency:
1515

1616
env:
1717
MAX_JOBS: 64
18-
MIN_PROJECTS_PER_JOB: 8
18+
MIN_PROJECTS_PER_JOB: 4
1919
MIN_PROJECTS_FOR_MATRIX: 4
2020
# See https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
2121
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
@@ -175,6 +175,7 @@ jobs:
175175
if ! anchor build; then
176176
echo "::error::anchor build failed for $project"
177177
echo "$project: anchor build failed" >> $GITHUB_WORKSPACE/failed_projects.txt
178+
rm -rf target node_modules
178179
cd - > /dev/null
179180
return 1
180181
fi
@@ -183,13 +184,13 @@ jobs:
183184
if ! anchor test; then
184185
echo "::error::anchor test failed for $project"
185186
echo "$project: anchor test failed" >> $GITHUB_WORKSPACE/failed_projects.txt
186-
rm -rf node_modules
187+
rm -rf target node_modules
187188
cd - > /dev/null
188189
return 1
189190
fi
190191
191192
echo "Build and tests succeeded for $project."
192-
rm -rf node_modules
193+
rm -rf target node_modules
193194
cd - > /dev/null
194195
return 0
195196
}

.github/workflows/native.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ concurrency:
1515

1616
env:
1717
MAX_JOBS: 64
18-
MIN_PROJECTS_PER_JOB: 8
18+
MIN_PROJECTS_PER_JOB: 4
1919
MIN_PROJECTS_FOR_MATRIX: 4
2020
# See https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
2121
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

.github/workflows/pinocchio.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ concurrency:
1515

1616
env:
1717
MAX_JOBS: 64
18-
MIN_PROJECTS_PER_JOB: 8
18+
MIN_PROJECTS_PER_JOB: 4
1919
MIN_PROJECTS_FOR_MATRIX: 4
2020
# See https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
2121
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

.github/workflows/quasar.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ concurrency:
1515

1616
env:
1717
MAX_JOBS: 64
18-
MIN_PROJECTS_PER_JOB: 8
18+
MIN_PROJECTS_PER_JOB: 4
1919
MIN_PROJECTS_FOR_MATRIX: 4
2020
# Force all JavaScript-based actions to use Node.js 24 runtime.
2121
# Node.js 20 actions are deprecated and will stop working June 2026.

0 commit comments

Comments
 (0)