Edge Functions have a hard wall-clock limit; you cannot raise it. Make the work fit:
- Upload the CSV to Storage, then run the import in the database with
copyvia apg_nettrigger orsupabase dbCLI. Postgres eats 20k rows in under a second. - Or split: the function processes 2,000 rows, writes progress to a table, and re-invokes itself.
For a one-off import, just run psql \copy from your laptop.
\copyfrom my laptop: 20,114 rows in about 3 seconds. I'd spent a day on the Edge Function.