Skip to content

debugger seems not working on Deno v2 - supabase-cli #612

@kallebysantos

Description

@kallebysantos

Bug report

  • I confirm this is a bug with Supabase, not with my own application.
  • I confirm I have searched the Docs, GitHub Discussions, and Discord.

Describe the bug

Recently an user did post on Reddit that chrome debugger is not working when using Deno v2.

Expected behaviour

Expected that debugger console to stop and be able to set breakpoints

To Reproduce

Create a new supabase project:

supabase init

Ensures Deno v2 inside config.toml

[edge_runtime]
deno_version = 2

Add a new function:

supabase functions new "hello-world"

Follow the instructions from Local Debugging with DevTools guide

Then run with inspect mode:

supabase functions serve --inspect-mode brk

Call the function:

curl -i --location --request POST 'http://127.0.0.1:54321/functions/v1/hello-world' \
          --header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24iLCJleHAiOjE5ODM4MTI5OTZ9.CRXP1A7WOeoJeXxjNni43kdQwgnWNReilDMblYTn_I0' \
          --header 'Content-Type: application/json' \
          --data '{"name":"Functions"}'
Functions log
❯ supabase functions serve --inspect-mode brk
Setting up Edge Functions runtime...
2025-09-19T12:50:28.057768398Z Serving functions on http://127.0.0.1:54321/functions/v1/<function-name>
2025-09-19T12:50:28.057790898Z  - http://127.0.0.1:54321/functions/v1/hello-world
2025-09-19T12:50:28.057799398Z Using supabase-edge-runtime-1.69.8 (compatible with Deno v2.1.4)
2025-09-19T12:50:45.846312853Z serving the request with supabase/functions/hello-world
2025-09-19T12:50:45.882565346Z Debugger listening on ws://0.0.0.0:8083/ws/8009a7cc-54d5-4619-b0d7-72ed5367903d
2025-09-19T12:50:45.882600096Z Visit chrome://inspect to connect to the debugger.
2025-09-19T12:50:45.882603596Z Worker is waiting for debugger to connect.
2025-09-19T12:50:46.309751611Z Debugger session started.
2025-09-19T12:50:46.433970238Z Debugger session ended
DevTools for Node Image

Additional context

Works when using v1 ✅

It works when setting the following on config.toml

[edge_runtime]
deno_version = 1
Functions log
❯ supabase functions serve --inspect-mode brk
Setting up Edge Functions runtime...
2025-09-19T12:35:18.511103362Z Serving functions on http://127.0.0.1:54321/functions/v1/<function-name>
2025-09-19T12:35:18.511135654Z  - http://127.0.0.1:54321/functions/v1/hello-world
2025-09-19T12:35:18.511144195Z Using supabase-edge-runtime-1.68.3 (compatible with Deno v1.45.2)
2025-09-19T12:43:35.026717197Z serving the request with supabase/functions/hello-world
2025-09-19T12:43:35.038306306Z Download https://jsr.io/@supabase/functions-js/meta.json
2025-09-19T12:43:35.325873338Z Download https://jsr.io/@supabase/functions-js/2.5.0_meta.json
2025-09-19T12:43:35.358095795Z Download https://jsr.io/@supabase/functions-js/2.5.0/src/edge-runtime.d.ts
2025-09-19T12:43:35.437479605Z Debugger listening on ws://0.0.0.0:8083/ws/77123729-cc26-49cd-ba40-efef32d666a7
2025-09-19T12:43:35.437502855Z Visit chrome://inspect to connect to the debugger.
2025-09-19T12:43:35.437505480Z Worker is waiting for debugger to connect.
2025-09-19T12:43:35.754201806Z Debugger session started.
2025-09-19T12:48:24.762411686Z Debugger session ended
DevTools for Node Image

System information

  • OS: macOS
  • Browser: brave
  • Version of supabase-cli: 2.40.7

Metadata

Metadata

Assignees

Labels

C-bugCategory: something isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions