Open penberg opened 1 year ago
Let's not show broken databases to users instead.
When they list databases, let's hide the ones without instances. When they create one that exists but has no instances, we just create the instance in the existing app.
Then we fix the problem on our side, instead of giving this responsibility to the user.
If we choose not to list broken databases, we'd have to make sure that a broken database doesn't count against the quota (or they can destroy the broken database manually), otherwise a user could find themselves into a situation where they are stuck with no way of moving forward on their own, and no way to even observe or diagnose the problem.
If you, for example, cancel
turso db create
command before it managed to spawn an instance, you will end up with a database that you cannot connect to. Some of the commands suggest runningdb replicate
to remedy the situation, but this is confusing. Let's do adb doctor
,db create --fix
or similar command instead to make it explicit that you're repairing a broken database.