Skip to content

Conversation

@Tobbe
Copy link
Member

@Tobbe Tobbe commented Oct 29, 2025

Node 20 is currently in maintenance mode, and will reach end of life 2026-04-30
Normally Cedar would switch to the next even numbered Node version. Which would be 22 in this case. But Node 24 is already out and is the current LTS version, so I'm jumping straight to that version.

Targeting CedarJS v2.0 for this PR

@netlify
Copy link

netlify bot commented Oct 29, 2025

Deploy Preview for cedarjs canceled.

Name Link
🔨 Latest commit be91f1f
🔍 Latest deploy log https://app.netlify.com/projects/cedarjs/deploys/6908a5cf0e295d00086324d6

@Tobbe Tobbe added this to the next-release-major milestone Oct 29, 2025
Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greptile Overview

Greptile Summary

Comprehensively updates CedarJS from Node 20 to Node 24 across all project templates, CI/CD workflows, documentation, and test fixtures.

Key changes:

  • Updated all package.json files to require engines.node = "=24.x" (15 files across templates and fixtures)
  • Modified all GitHub Actions workflows to use Node 24 in CI/CD pipelines
  • Updated create-cedar-rsc-app prerequisite validation to enforce Node 24
  • Deleted docs/.node-version file (previously pinned to 20.18.1)
  • Updated boundary test cases: Node 20 for low boundary, Node 25 for high boundary
  • Fixed unrelated typo: renamed getCrxrscaVersion to getCcrscaVersion in RSC app creator
  • Marked Node 24 upgrade as completed in README roadmap

Issues found:

  • The semver syntax '=24' in prerequisites.ts:29 may not work correctly - should use '>=24.0.0 <25.0.0' or '^24.0.0' instead

Confidence Score: 3/5

  • This PR requires attention due to a critical semver syntax issue in the Node version validation
  • The changes are comprehensive and systematic across all necessary files, but there's a critical bug in packages/create-cedar-rsc-app/src/prerequisites.ts:29 where the semver range syntax '=24' is likely invalid. The semver library may not recognize =24 as a valid range - it should be '>=24.0.0 <25.0.0' or '^24.0.0' to properly match Node 24.x versions. This could cause the version check to fail unexpectedly or behave incorrectly. All other changes (CI workflows, package.json files, documentation) are correct and consistent.
  • packages/create-cedar-rsc-app/src/prerequisites.ts requires immediate attention for the semver syntax fix

Important Files Changed

File Analysis

Filename Score Overview
packages/create-cedar-rsc-app/src/prerequisites.ts 3/5 Updated Node version check from >=20.10 to =24, enforcing strict version requirement
.github/actions/set-up-job/action.yml 5/5 Updated Node version from 20 to 24 in CI setup action
.github/workflows/create-cedar-app-test.yml 5/5 Updated test boundary cases: Node 20 for low boundary, Node 25 for high boundary
docs/docs/quick-start.md 5/5 Updated documentation to reflect Node 24.x requirement
packages/create-cedar-app/templates/js/package.json 5/5 Updated engines.node from =20.x to =24.x

Sequence Diagram

sequenceDiagram
    participant Dev as Developer
    participant CLI as create-cedar-app/rsc-app CLI
    participant Check as Node Version Check
    participant Template as Project Templates
    participant CI as GitHub Actions CI

    Note over Dev,CI: Node 24 Upgrade Flow

    Dev->>CLI: Run yarn create cedar-app
    CLI->>Check: Execute checkNodeVersion()
    Check->>Check: Verify semver.satisfies(version, '=24')
    alt Node Version < 24 or > 24
        Check-->>CLI: ❌ Error: Must use Node.js v24
        CLI-->>Dev: Exit with error
    else Node Version = 24.x
        Check-->>CLI: ✅ Version requirements met
        CLI->>Template: Copy template files
        Template->>Template: Set engines.node = "=24.x" in package.json
        Template-->>CLI: Project created
        CLI-->>Dev: ✅ Project ready
    end

    Note over CI: CI/CD Pipeline

    Dev->>CI: Push code / Create PR
    CI->>CI: Setup Node v24 (set-up-job action)
    CI->>CI: Run build, lint, test jobs
    CI->>CI: Run smoke tests
    CI->>CI: Run integration tests
    CI-->>Dev: CI Results

    Note over CI: Boundary Testing
    CI->>CI: Test with Node 20 (should fail)
    CI->>CI: Test with Node 25 (should fail)
Loading

21 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

@Tobbe Tobbe mentioned this pull request Nov 7, 2025
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.

2 participants