W
Wasp-langβ€’14mo ago
Kaparopi

Error when running new app

I seem to get this error whenever executing wasp start command : [Server] src/auth/utils.ts(56,3): error TS2322: Type 'SigningKeyCallback' is not assignable to type '{ id: any; }'. The only thing I did was : wasp new app -t saas, then the db migration command, then wasp start. I dont do any action on the app. Any idea what could cause this ? Thank you !
14 Replies
Vinny (@Wasp)
Vinny (@Wasp)β€’14mo ago
interesting. I'll take a look. But as the error says, there seems to be a type error in the utils.ts file thanks for bringing this up!
Kaparopi
KaparopiOPβ€’14mo ago
Thank you, for the moment i manually changed the return type of this method in the .wasp folder and it fixes the problem :export async function verifyToken(token: string): Promise<SigningKeyCallback> { return verify(token); }
Vinny (@Wasp)
Vinny (@Wasp)β€’14mo ago
hmm. you shouldn't have to change anything in the .wasp file because that's where Wasp will always regenerate new code for you did you fill in your API keys for Google Auth? actually this may be an issue with our social auth, but we've never seen this before have we @miho ?
miho
mihoβ€’14mo ago
I'll try to recreate it πŸ‘
Vinny (@Wasp)
Vinny (@Wasp)β€’14mo ago
I just tried, and didn't get any error @Kaparopi try with a fresh project, and make sure you: - first start a db in one terminal with wasp db start, - then in another terminal run wasp db migrate-dev - change the file .env.server.example to .env.server and fill in the google api keys (you can use any random string just to get the app started)
GOOGLE_CLIENT_ID=your-ids-and-secrets
GOOGLE_CLIENT_SECRET=your-ids-and-secrets
GOOGLE_CLIENT_ID=your-ids-and-secrets
GOOGLE_CLIENT_SECRET=your-ids-and-secrets
- and finally wasp start let me know if you're still running into errors
miho
mihoβ€’14mo ago
Running all of the commands:
wasp new app -t saas
cd app
wasp db migrate-dev

# Update my .env.server with Google ID and Secret

wasp db start
wasp new app -t saas
cd app
wasp db migrate-dev

# Update my .env.server with Google ID and Secret

wasp db start
and the app runs just fine πŸ€·β€β™‚οΈ
Kaparopi
KaparopiOPβ€’14mo ago
@Vinny (@Wasp) I did create a fresh app with the google keys set but I still get the error. I use wasp cli 0.11.7, on mac m1.
Vinny (@Wasp)
Vinny (@Wasp)β€’14mo ago
hmm I also don't get any errors. Did you install wasp via curl?
curl -sSL https://get.wasp-lang.dev/installer.sh | sh -s
curl -sSL https://get.wasp-lang.dev/installer.sh | sh -s
Kaparopi
KaparopiOPβ€’14mo ago
yes
miho
mihoβ€’14mo ago
Could you maybe record a quick video of you doing the steps above? I'm not sure what to do next to get more info πŸ˜‚
martinsos
martinsosβ€’14mo ago
Which version of node are you using @Kaparopi ?
Kaparopi
KaparopiOPβ€’14mo ago
v18.18.2
MEE6
MEE6β€’14mo ago
Wohooo @Kaparopi, you just became a Waspeteer level 1!
martinsos
martinsosβ€’14mo ago
Yeah that all sounds right. @Kaparopi the problem is we are not able to reproduce the error, nor have we seen it before, so that makes it hard for us to do anyting about it. If you can provide us with any extra info that could help with this, like more info about the exact steps you did, that might help.
Want results from more Discord servers?
Add your server