You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First off, handy utility. It saves me quite a bit of time when working on schema/data migrations. So, thank you!
I've been using a toml file for configuration, which I keep in my user directory. I managed to shoot myself in the foot today by doing the following:
Capturing a snapshot when I was outside of that dir, thinking that I was capturing the desired db (when really I guess I captured some top-level Postgres database)
Attempting to restore in the directory I captured in. This in an of itself yields an error like so:
dslr restore test2
Failed to restore snapshot
zero-length delimited identifier at or near """"
LINE 1: DROP DATABASE ""
^
Not thinking "Oh I captured garbage, be careful not to restore garbage" I navigated back to my home directory and ran the restore again and restored garbage over my db.
So, user error for sure, but I wonder if making it clear to people that the URL value is empty when running operations would save people from similar issues.
I'm not sure if DSLR will check the path for a toml file, but wonder if that would be a worthwhile enhancement. The DATABASE_URL environment variable is generic enough that I am hesitant to use it for config.
Thanks again.
The text was updated successfully, but these errors were encountered:
tvuotila
added a commit
to tvuotila/DSLR
that referenced
this issue
Aug 30, 2023
Hello,
First off, handy utility. It saves me quite a bit of time when working on schema/data migrations. So, thank you!
I've been using a toml file for configuration, which I keep in my user directory. I managed to shoot myself in the foot today by doing the following:
So, user error for sure, but I wonder if making it clear to people that the URL value is empty when running operations would save people from similar issues.
I'm not sure if DSLR will check the path for a toml file, but wonder if that would be a worthwhile enhancement. The DATABASE_URL environment variable is generic enough that I am hesitant to use it for config.
Thanks again.
The text was updated successfully, but these errors were encountered: