Describe the bug
supabase gen types --lang typescript --db-url "postgresql://postgres:[email protected]:54322/postgres" fails with supabase start is not running even though the database is reachable and we intentionally do not use supabase start (containers are managed with Docker Compose). Debug output shows it still resolves local profile/project state (Using profile: supabase) and fails in internal/gen/types/types.go:65.
To Reproduce
- Run local Postgres with Docker Compose (no supabase start), reachable at 127.0.0.1:54322.
- Run: (with appropriate db-url)
supabase gen types --lang typescript --db-url "postgresql://postgres:[email protected]:54322/postgres" --debug
- See error and stack trace:
supabase gen types --lang typescript --db-url "postgresql://postgres:[email protected]:54322/postgres" --debug
open /Users/user/.supabase/profile: no such file or directory
Supabase CLI
Using profile: supabase (supabase.co)
github.com/supabase/cli/internal/utils/misc.go:151 (0x103875c68)
github.com/supabase/cli/internal/utils/misc.go:145 (0x10388030c)
github.com/supabase/cli/internal/gen/types/types.go:65 (0x10388030d)
github.com/supabase/cli/cmd/gen.go:99 (0x104f3adcc)
github.com/spf13/[email protected]/command.go:1015 (0x102dc1fd4)
github.com/spf13/[email protected]/command.go:1148 (0x102dc2750)
github.com/supabase/cli/cmd/root.go:173 (0x104f497a8)
github.com/supabase/cli/main.go:11 (0x104f4e15c)
internal/runtime/atomic/types.go:194 (0x102c0f168)
runtime/asm_arm64.s:1268 (0x102c4ad14)
supabase start is not running.
Expected behavior
gen types should connect directly to the provided --db-url and generate types without requiring local supabase start state.
System information
- Ticket ID:
3748954abc3e406190420d9f5c015245
- Version of OS: macOS (Apple Silicon)
- Version of CLI: reproduces on 2.90.0 and 2.100.0
- Version of Docker: local Docker daemon via OrbStack
- Versions of services: custom compose stack (Postgres + PostgREST + Storage + imgproxy + Kong)
Additional context
Describe the bug
supabase gen types --lang typescript --db-url "postgresql://postgres:[email protected]:54322/postgres"fails withsupabase start is not runningeven though the database is reachable and we intentionally do not use supabase start (containers are managed with Docker Compose). Debug output shows it still resolves local profile/project state (Using profile: supabase) and fails in internal/gen/types/types.go:65.To Reproduce
supabase gen types --lang typescript --db-url "postgresql://postgres:[email protected]:54322/postgres" --debugExpected behavior
gen types should connect directly to the provided --db-url and generate types without requiring local supabase start state.
System information
3748954abc3e406190420d9f5c015245Additional context