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

vercel dev must not recursively invoke itself. #152

Open
TrofinSorin opened this issue Sep 19, 2022 · 6 comments
Open

vercel dev must not recursively invoke itself. #152

TrofinSorin opened this issue Sep 19, 2022 · 6 comments

Comments

@TrofinSorin
Copy link

Hello, i've deployed a hazel server for autoupdating electron app.

But i get this error when i try to start the server locally.

vercel dev must not recursively invoke itself. Check the Development Command in the Project Settings or the dev script in package.json

@mikekberg
Copy link

I'm getting this as well, I got a bit further but added a new "start" task in package json scripts.

  "scripts": {
    "start": "micro",
    "dev": "npx vercel dev",
    "test": "xo && jest",
    "precommit": "lint-staged"
  },

You can start the server by running npm run start but I run into other issues when hitting any route.

@Angusross111
Copy link

I got it running locally using micro-dev which is the suggested way to run micro in development.

"dev": "micro-dev ./lib/server.js",

You also need to add the required environment variables. I used dotenv and created a .env file in the root with:

ACCOUNT=<your-account>
REPOSITORY=<your-repo>
TOKEN=<token-if-private>
URL=http://localhost:3000

and added require('dotenv').config() at the top of /lib/index.js

@user72356
Copy link

user72356 commented Oct 27, 2022

I also have this issue in a plain regular React Vite app, with the following script:

"dev": "vercel dev"

I have the same error when running vercel dev from the command line.

I'm not sure what's recursive about it. Is the vercel cli trying to run the dev script? And why? Of course it can be fixed with using a different name for the script, but it bothers me.

"vercel-dev": "vercel dev"

@ianrtracey
Copy link

Also running into this issue

@jjalonso
Copy link

jjalonso commented Nov 1, 2023

Guys, please check this as it is a feature.

https://vercel.com/docs/errors/error-list#recursive-invocation-of-commands

@antoinerousseau
Copy link

We're using vc dev, e.g.

"dev": "vc dev -A vercel.local.json --listen 8000"

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

No branches or pull requests

7 participants