I have a site deployed on Vercel where all cells return Error: Failed to execute 'fetch' on 'Window': Invalid value
.
This is only a problem with the deployment, local works perfectly fine. I’m using Supabase for my local and deployed DB. The two DBs are setup the exact same way.
Local:
Deployed:
New info: When I try and create a new user, I get 405 Method Not Allowed
on auth in my network tab.
I think your redwood.toml has to be adjusted.
Did you run the setup for Vercel? That should automatically do it:
yarn rw setup deploy vercel
It should have an apiUrl of “/api”
[web]
title = "GigStack"
port = 8910
apiUrl = "/api/functions" # You can customize graphql and dbauth urls individually too: see https://redwoodjs.com/docs/app-configuration-redwood-toml#api-paths
includeEnvironmentVariables = [
"DATABASE_URL",
"DIRECT_URL"
]
change to:
apiUrl = "/api"
that’s first thing I noticed at least
I ended up switching to hosting on Render which solved this issue, but when I try and signup I get this error in my network tab:
.redwood/functions/auth?method=getToken 500 (Internal Server Error)
Hi @aidankmcalister can you share any logs?
It could be that you have not set the secret envar needed for the cookie signing in dbAuth or perhaps you have some old cookies in your browser that are no longer compatible.
I’d suggest clearing cookies and localStorage and trying again — or share the logs issue which may point to something specific