skip to Main Content

I am trying to play around with Firebase’s new Genkit product but whenever I run the npx genkit start command, I get one of two errors:

throw Error(`Unexpected runtime while starting app code: ${runtime}`);
npm ERR! Missing script: "build"

2

Answers


  1. Chosen as BEST ANSWER

    I didn't read the docs and was using an older version of node. Genkit requires Node.js 20 or later.

    To fix, this I just updated Node:

    nvm install v20.13.1
    

    Then I reran the install command:

    npm i -g genkit
    

    And everything worked as expected. Wish the error message was not as cryptic!


  2. First check if genkit is installed globally

    npm ls --depth=0 
    

    If genkit is in the list, run below cmd to init

    npx genkit init
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search