Troubleshooting Edge Functions
Unable to call Edge Function#
If you're unable to call your Edge Function or are experiencing any CORS issues, even though you followed the CORS guide, please head over to app.supabase.com/project/_/functions, select your function from the list & click Logs. Do you see any errors listed there?
There are two debugging tools available: Invocations and Logs. Invocations shows the Request and Response for each execution, while Logs shows any platform events, including deployments and errors.
Unable to deploy Edge Function#
- Make sure you're on the latest version of the Supabase CLI.
- Run the deploy command with the
--debug
flag. - Run the deploy command with the
--legacy-bundle
flag and see if that works. - If the output from the commands above does not help you to resolve the issue, please open a support ticket via the Supabase Dashboard (by clicking the "Help" button at the top right) and include all output from the commands mentioned above.
Edge Function takes too long to respond#
- Head over to app.supabase.com/project/_/functions, select your function from the list & click Logs.
- In the looks, look for the
booted
event and check if they have consistent boot times.- If the boot times are similar, it's likely an issue with your function's code, like a large dependency etc.
- If only some of the
booted
events are slow, please find the affectedregion
in the metadata and submit a support request via the "Help" button at the top.
Issues serving Edge Functions locally with the Supabase CLI#
- Make sure you're on the latest version of the Supabase CLI.
- Run the serve command with the
--debug
flag. - Support engineers can then try to run the provided sample code locally and see if they can reproduce the issue.
- Search the Edge Runtime and CLI repos for the error message, to see if it has been reported before.
- If the output from the commands above does not help you to resolve the issue, please open a support ticket via the Supabase Dashboard (by clicking the "Help" button at the top right) and include all output and details about your commands.