strapi / strapi-starter-next-ecommerce

Strapi Starter Next.js E-commerce
strapi-starter-next-ecommerce.strapijs.vercel.app
MIT License
215 stars 72 forks source link

Main instalation don,t work #21

Open jrsanchezalcala opened 2 years ago

jrsanchezalcala commented 2 years ago

i exec

npx create-strapi-starter my-project next-ecommerce before downloading all dependencies and select quickstart it throws the next error.

npx create-strapi-starter my-project next-ecommerce
? Choose your installation type Quickstart (recommended)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
SyntaxError: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at getPackageInfo (/home/juan/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/fetch-npm-starter.js:19:27)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async getStarterInfo (/home/juan/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/build-starter.js:109:26)
    at async buildStarter (/home/juan/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/build-starter.js:133:7)

the same thing happen with yarn.

my node version is 16.13.0

Denis2222 commented 2 years ago

Same with yarn and node v14.15.4

burdulixda commented 2 years ago

That's because the installation scripts tries to use Strapi v4, which was released just a few days ago, but this starter template is not yet compatible with it. You can run npx create-strapi-starter@3 my-project next-ecommerce The command will install starter template with Strapi v3 base. Also, you should probably use Node v14 LTS for Strapi projects since it's officially supported and v16 is not.

bradharms commented 2 years ago

@burdulixda Can this information be listed in the documentation?

burdulixda commented 2 years ago

@burdulixda Can this information be listed in the documentation?

Sure.

Ronyo commented 2 years ago

What will I have to update to use Strapi v4? After the template is installed will I just have to update Strapi to v4 or will the upgrade path be more complicated?

basic-steve commented 2 years ago

Two months later you still have this issue, I mean, this is your calling card, great. I certainly NOT try your product if this is the support I'll get

aaegorof commented 2 years ago

Still have the same error on both yarn and npx

Tonikprofik commented 2 years ago

took me a while, to get here. Installation still does not work with npx create-strapi-starter@3 my-project https://github.com/strapi/strapi-starter-next-ecommerce nor yarn for both Quickstart nor Custom option

PS D:\NextJS> npx create-strapi-starter@3 StrapiNextEcomm next-ecommerce
? Choose your installation type Custom (manual settings)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
SyntaxError: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at getPackageInfo (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\fetch-npm-starter.js:19:27)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at async getStarterInfo (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\build-starter.js:109:26)
    at async buildStarter (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\build-starter.js:133:7)
PS D:\Tryhard\Projects\NextJS> npx create-strapi-starter@3 StrapiNextEcomm https://github.com/strapi/strapi-starter-next-ecommerce
? Choose your installation type Quickstart (recommended)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
SyntaxError: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at getPackageInfo (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\fetch-npm-starter.js:19:27)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at async getStarterInfo (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\build-starter.js:109:26)
    at async buildStarter (C:\Users\Tonik Profik\AppData\Local\Yarn\Data\global\node_modules\create-strapi-starter\utils\build-starter.js:133:7)
PS D:\Tryhard\Projects\NextJS> 

on node 14.15.1 LTS

OneFJef commented 2 years ago

Not sure why this is closed. As of March 26, 2022 the install still does not work.


? Choose your installation type Quickstart (recommended)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
Error: Command failed with exit code 1: yarn info next-ecommerce --json
Usage Error: No project found in /Users/jef/code

$ yarn info [-A,--all] [-R,--recursive] [-X,--extra #0] [--cache] [--dependents] [--manifest] [--name-only] [--virtuals] [--json] ...
    at makeError (/Users/jef/.npm/_npx/ecd569b0a81a6814/node_modules/execa/lib/error.js:60:11)
    at handlePromise (/Users/jef/.npm/_npx/ecd569b0a81a6814/node_modules/execa/index.js:118:26)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async getPackageInfo (/Users/jef/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/fetch-npm-starter.js:18:24)
    at async getStarterInfo (/Users/jef/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/build-starter.js:109:26)
    at async buildStarter (/Users/jef/.npm/_npx/ecd569b0a81a6814/node_modules/create-strapi-starter/utils/build-starter.js:133:7)```
Ronyo commented 2 years ago

Same here. I'd love for someone to look into this.