Skip to content

ci: upgrade deprecated GitHub Actions before Node.js 24 deadline (June 2nd)#160

Open
TimeToBuildBob wants to merge 4 commits into
ActivityWatch:masterfrom
TimeToBuildBob:bob/ci-node20-action-upgrades
Open

ci: upgrade deprecated GitHub Actions before Node.js 24 deadline (June 2nd)#160
TimeToBuildBob wants to merge 4 commits into
ActivityWatch:masterfrom
TimeToBuildBob:bob/ci-node20-action-upgrades

Conversation

@TimeToBuildBob
Copy link
Copy Markdown
Contributor

Problem

GitHub Actions will force Node.js 24 by default starting June 2nd, 2026 (10 days away). The following actions in build.yml use Node.js 20 and will break:

Action Old New
actions/checkout v2 / v3 v4
actions/cache v3 v4
actions/cache/restore v3 v4
actions/setup-java v1 v4 + distribution: temurin
android-actions/setup-android v2 v3
actions/upload-artifact v3 v4
actions/download-artifact v3 v4
Wandalen/wretry.action @master @v3.8.0_js_action (pinned)

Notes

  • actions/setup-java@v2+ requires a distribution parameter — added temurin (Eclipse Temurin, the standard OpenJDK distribution used by GH-hosted runners)
  • ruby/setup-ruby, adnsio/setup-age-action, custom ActivityWatch/check-version-format-action are unchanged (not affected by the Node.js 20 deprecation)
  • Wandalen/wretry.action@master was pinned to v3.8.0_js_action (the already-deployed version) for reproducibility

@greptile-apps
Copy link
Copy Markdown

greptile-apps Bot commented May 22, 2026

Greptile Summary

This PR upgrades all GitHub Actions that used deprecated Node.js 20 runtimes before the June 2nd, 2026 deadline, adds fork-PR guards to skip secret-dependent steps on fork pull requests, and modernises the Android emulator setup to use current cmdline-tools paths.

  • Action upgrades: actions/checkout, actions/cache, actions/cache/restore, actions/setup-java (+ distribution: temurin), android-actions/setup-android, actions/upload-artifact, actions/download-artifact, and Wandalen/wretry.action all bumped to Node-20/Node-24-compatible versions.
  • Artifact name fix: Matrix build-apk jobs now upload to aw-android-${{ matrix.type }} and both release jobs download with pattern: aw-android-* + merge-multiple: true, resolving the v4 name-collision behavior.
  • softprops/action-gh-release@v1 in the release-gh job was not updated; v1 uses Node.js 16 (also deprecated) and will break tag-triggered releases after June 2nd.

Confidence Score: 4/5

Safe to merge for day-to-day CI, but the release-gh job will break on every production tag push after June 2nd because softprops/action-gh-release@v1 was not upgraded.

All build, test, and artifact jobs are correctly upgraded and the fork-PR guard logic is sound. The one gap is softprops/action-gh-release@v1 in release-gh: it runs on Node.js 16 and will fail after the June 2nd deadline, silently blocking every production release cut from a tag.

.github/workflows/build.yml — specifically the release-gh job's softprops/action-gh-release@v1 step.

Important Files Changed

Filename Overview
.github/workflows/build.yml Upgrades most deprecated GitHub Actions ahead of the June 2nd Node.js 24 deadline, adds fork-PR guards, fixes artifact name collisions in the matrix build, and modernises Android emulator setup — but softprops/action-gh-release@v1 (Node.js 16) in release-gh was not upgraded and will break release tag runs after the deadline.

Reviews (4): Last reviewed commit: "ci: bump Test job runner from retired ub..." | Re-trigger Greptile

Comment thread .github/workflows/build.yml
@TimeToBuildBob
Copy link
Copy Markdown
Contributor Author

Addressed the Greptile review findings:

Artifact name collision (upload-artifact@v4 breaking change): The matrix build-apk jobs were both uploading to name: aw-android. With v3 this silently merged; v4 rejects concurrent uploads to the same name. Fixed by:

  • Upload: name: aw-android-${{ matrix.type }} (produces aw-android-apk and aw-android-aab)
  • Download in release jobs: pattern: aw-android-* + merge-multiple: true (merges both into dist/ as before)

Unused NODE_VERSION: '16': Removed — it was never referenced in the workflow and Node 16 is EOL.


The two CI failures (Get latest versionCode and Build aw-server-rust) are pre-existing issues unrelated to this PR:

  • Get latest versionCode: fails because KEY_FASTLANE_API secret is empty on PR branches (expected — secrets aren't available here)
  • Build aw-server-rust: fails with a Rust type inference error in the time-0.3.30 crate (pre-existing; master CI also fails this job)

@TimeToBuildBob
Copy link
Copy Markdown
Contributor Author

Follow-up after comparing this branch against #158 and the other open fork PRs: these failures were branch-specific, not ambient repo breakage.

Pushed 7198ce6 to bob/ci-node20-action-upgrades:

  • gate Ruby/age/fastlane update_version and build-apk behind the same-repo PR check so fork PRs stop failing on missing secrets and use the committed build.gradle versionCode as fallback
  • pin Rust to 1.79.0 for aw-server-rust@dc70318, which avoids the time crate E0282 failure on newer toolchains
  • bootstrap emulator tool discovery for the setup-android@v3 path changes so test-e2e can find sdkmanager, avdmanager, emulator, and adb

The earlier artifact-name/download fix is still in place. GitHub Actions has already started a fresh Build run on this commit.

Actions will be forced to run with Node.js 24 starting June 2nd, 2026.
Update all deprecated action versions before the deadline:

- actions/checkout: v2/v3 → v4
- actions/cache: v3 → v4
- actions/cache/restore: v3 → v4
- actions/setup-java: v1 → v4 (add distribution: temurin, now required)
- android-actions/setup-android: v2 → v3
- actions/upload-artifact: v3 → v4
- actions/download-artifact: v3 → v4
- Wandalen/wretry.action: @master → @v3.8.0_js_action (pin stable)
upload-artifact@v4 no longer allows concurrent jobs to write to the
same artifact name. Split the upload into aw-android-apk and
aw-android-aab, then use pattern + merge-multiple on download so
release jobs still receive both files in one dist/ directory.

Also remove the unused NODE_VERSION env var (EOL Node 16, never referenced).
GitHub retired the ubuntu-20.04 hosted-runner image; the Test job was
intermittently stuck forever waiting for a runner that would never
appear. ubuntu-22.04 is the stable LTS replacement.
@TimeToBuildBob TimeToBuildBob force-pushed the bob/ci-node20-action-upgrades branch from 7198ce6 to 380851e Compare May 22, 2026 14:08
@TimeToBuildBob
Copy link
Copy Markdown
Contributor Author

Added commit 380851e to bump the Test job runner from retired ubuntu-20.04 to ubuntu-22.04. This was the intermittent "waiting for a runner to pick up this job" stall Erik flagged on #156 — GitHub retired the ubuntu-20.04 image so that job sat forever. Also rebased onto latest master (was 1 commit behind).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant