Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Astro 2.0 Node Version Check Issue #5967

Closed
1 task
SteveEdson opened this issue Jan 24, 2023 · 6 comments · Fixed by #5972
Closed
1 task

Astro 2.0 Node Version Check Issue #5967

SteveEdson opened this issue Jan 24, 2023 · 6 comments · Fixed by #5972
Labels
- P5: urgent Fix build-breaking bugs affecting most users, should be released ASAP (priority)

Comments

@SteveEdson
Copy link

What version of astro are you using?

2.0.0

Are you using an SSR adapter? If so, which one?

None

What package manager are you using?

yarn

What operating system are you using?

Mac / Linux

Describe the Bug

Getting the following errors:

Locally

Node.js v16.13.1 is not supported by Astro!
Please upgrade Node.js to a supported version: ">=16.12.0"

On Cloudflare pages

Node.js v16.19.0 is not supported by Astro!
Please upgrade Node.js to a supported version: ">=16.12.0"

Link to Minimal Reproducible Example

N/A

Participation

  • I am willing to submit a pull request for this issue.
@matthewp matthewp added the - P5: urgent Fix build-breaking bugs affecting most users, should be released ASAP (priority) label Jan 24, 2023
@matthewp
Copy link
Contributor

Pinging @bluwy in case he has any ideas. I haven't been able to reproduce this personally.

@ZackarySantana
Copy link

const semver = await import('semver');

It's possible 'semver' isn't installed/properly and is throwing a module not found, the catch does not handle this and always says it is a version of node that doesn't work, that's the only way I was able to reproduce this

@arkinmodi
Copy link

I also experienced issue this when trying to upgrade to Astro 2.0.

Node.js v16.18.0 is not supported by Astro!
Please upgrade Node.js to a supported version: ">=16.12.0"

I was able to reproduce it with this package.json.

{
  "name": "@example/basics",
  "type": "module",
  "version": "0.0.1",
  "private": true,
  "scripts": {
    "dev": "astro dev",
    "start": "astro dev",
    "build": "astro build",
    "preview": "astro preview",
    "astro": "astro"
  },
  "dependencies": {
    "@commitlint/cli": "^16.3.0",
    "astro": "^2.0.0"
  }
}

It might be some sort of dependency conflict? Updating @commitlint/cli to the latest fixes the issue.

@netanel-haber
Copy link

I also experienced issue this when trying to upgrade to Astro 2.0.

Node.js v16.18.0 is not supported by Astro!
Please upgrade Node.js to a supported version: ">=16.12.0"

I was able to reproduce it with this package.json.

{
  "name": "@example/basics",
  "type": "module",
  "version": "0.0.1",
  "private": true,
  "scripts": {
    "dev": "astro dev",
    "start": "astro dev",
    "build": "astro build",
    "preview": "astro preview",
    "astro": "astro"
  },
  "dependencies": {
    "@commitlint/cli": "^16.3.0",
    "astro": "^2.0.0"
  }
}

It might be some sort of dependency conflict? Updating @commitlint/cli to the latest fixes the issue.

Still happening to me actually, with node -v=v16.18.0, using "astro": "^2.0.2" (created by pnpm create astro@latest --template blog).

@bluwy
Copy link
Member

bluwy commented Jan 30, 2023

@netanel-haber does it happen with npm? Perhaps they are stale deps lingering. It works for me with that Node version

@netanel-haber
Copy link

Tried with pnpm and yarn after deleting node_modules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
- P5: urgent Fix build-breaking bugs affecting most users, should be released ASAP (priority)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants