cli
cli copied to clipboard
`supabase gen types` has different connection requirements based on generated language?
Describe the bug
The Supabase CLI's gen types command will successfully connect to the DB to generate Typescript types, but if you add the Swift flag, suddenly wants you to connect a different way...
To Reproduce
~/Desktop % supabase gen types
Selected project: [REDACTED]
export type Json =
| string
| number
| boolean
| null
| { [key: string]: Json | undefined }
| Json[]
export type Database = {
[...SNIPPED...]
export const Constants = {
public: {
Enums: {},
},
} as const
~/Desktop % supabase gen types --lang swift
Selected project: [REDACTED]
Unable to generate swift types for selected project. Try using --db-url flag instead.
Try rerunning the command with --debug to troubleshoot the error.
Expected behavior I expect my language choice to be irrelevant to my connection method.
System information
Rerun the failing command with --create-ticket flag.
- Ticket ID: e0d4bd6328554ac288953a236320e4e4
- Version of OS: MacOS 15.5 (24F74)
- Version of CLI: 2.24.3
- Version of Docker: None
- Versions of services:
SERVICE IMAGE | LOCAL | LINKED
------------------------|------------------------|------------
supabase/postgres | 15.8.1.044 | 15.8.1.044
supabase/gotrue | v2.174.0 | v2.174.0
postgrest/postgrest | v12.2.3 | v12.2.3
supabase/realtime | v2.36.7 | -
supabase/storage-api | v1.23.0 | -
supabase/edge-runtime | v1.67.4 | -
supabase/studio | 2025.06.02-sha-8f2993d | -
supabase/postgres-meta | v0.89.3 | -
supabase/logflare | 1.12.0 | -
supabase/supavisor | 2.5.1 | -
Additional context If applicable, add any other context about the problem here.
- Browser [e.g. chrome, safari]
- Version of supabase-js [e.g. v2.22.0]
- Version of Node.js [e.g. v16.20.0]
(N/A)