Janne is experiencing errors when running Sanity init after updating Sanity.
6 replies
Last updated: Aug 3, 2022
J
Hi,I was starting a new Sanity project and I updated my Sanity beforehand. Now I’m getting errors when I run Sanity init. I tried using different project names, different types of datasets (no data, movie, …) and nothing works. Screenshot of the terminal here.
Aug 2, 2022, 11:48 PM
J
that’s the entire error
Aug 2, 2022, 11:53 PM
J
janne@Users-MBP Developer % npm install -g @sanity/clinpm WARN config global
changed 1 package, and audited 2 packages in 3s
found
0 vulnerabilitiesjanne@Users-MBP Developer % sanity init
You’re setting up a
Sanity.io project!We’ll make sure you’re logged in with
Sanity.io .Then, we’ll install a Sanity Studio for your project.
Press ctrl + C at any time to quit.
Looks like you already have a Sanity-account. Sweet!
?
Select project to use Create new project?
Your project name: FormsYour content will be stored in a dataset that can be public or private, depending on
whether you want to query your content with or without authentication.
The default dataset configuration has a public dataset named “production”.
?
Use the default dataset configuration? No?
Name of your first dataset: production?
Choose dataset visibility – this can be changed later Private (authenticated requests only)Please note that while documents are private, assets (files and images) are still public
✔️ Creating dataset?
Project output path: /Users/janne/Developer/forms?
Select project template Movie project (schema + sample data)?
Add a sampling of sci-fi movies to your dataset on the hosted backend? Yes
✔️ Bootstrapping files from template
✔️ Resolving latest module versions
✔️ Creating default project files
✖️ Resolving dependencies
Error: Command failed :(
at ~/.nvm/versions/node/v16.14.0/lib/node_modules/@sanity/cli/bin/sanity-cli.js
:3614:2582 at processTicksAndRejections (node
:internal/process/task_queues:96:5) at async e.default (~/.nvm/versions/node/v16.14.0/lib/node_modules/@sanity/cli/bin/sanity-cli.js
:4884:10714)
--global,
--localare deprecated. Use
--location=globalinstead.
changed 1 package, and audited 2 packages in 3s
found
0 vulnerabilitiesjanne@Users-MBP Developer % sanity init
You’re setting up a
Sanity.io project!We’ll make sure you’re logged in with
Sanity.io .Then, we’ll install a Sanity Studio for your project.
Press ctrl + C at any time to quit.
Looks like you already have a Sanity-account. Sweet!
?
Select project to use Create new project?
Your project name: FormsYour content will be stored in a dataset that can be public or private, depending on
whether you want to query your content with or without authentication.
The default dataset configuration has a public dataset named “production”.
?
Use the default dataset configuration? No?
Name of your first dataset: production?
Choose dataset visibility – this can be changed later Private (authenticated requests only)Please note that while documents are private, assets (files and images) are still public
✔️ Creating dataset?
Project output path: /Users/janne/Developer/forms?
Select project template Movie project (schema + sample data)?
Add a sampling of sci-fi movies to your dataset on the hosted backend? Yes
✔️ Bootstrapping files from template
✔️ Resolving latest module versions
✔️ Creating default project files
✖️ Resolving dependencies
Error: Command failed :(
at ~/.nvm/versions/node/v16.14.0/lib/node_modules/@sanity/cli/bin/sanity-cli.js
:3614:2582 at processTicksAndRejections (node
:internal/process/task_queues:96:5) at async e.default (~/.nvm/versions/node/v16.14.0/lib/node_modules/@sanity/cli/bin/sanity-cli.js
:4884:10714)
Aug 2, 2022, 11:59 PM
I think it might have created some files in that folder already, could you try running
npm installin
/Users/janne/Developer/formsand seeing if that works?
Aug 3, 2022, 1:41 AM
J
that worked indeed, thanks
Aug 3, 2022, 2:00 AM
Sanity– build remarkable experiences at scale
Sanity is a modern headless CMS that treats content as data to power your digital business. Free to get started, and pay-as-you-go on all plans.