diff options
author | Jeyachandran Rathnam <jai.rathnem@gmail.com> | 2022-12-22 13:26:37 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-22 13:26:37 -0500 |
commit | 5c9be9c76021ac54f425f10e8f935532d3197de5 (patch) | |
tree | 24c6c0cd7f91dfc9bb28900b4e79bc11be697e77 /synapse | |
parent | Update docs about ruff vs. flake8. (diff) | |
download | synapse-5c9be9c76021ac54f425f10e8f935532d3197de5.tar.xz |
Check sqlite database file exists before porting. (#14692)
To avoid creating an empty SQLite file if the given path is incorrect.
Diffstat (limited to 'synapse')
-rwxr-xr-x | synapse/_scripts/synapse_port_db.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/_scripts/synapse_port_db.py b/synapse/_scripts/synapse_port_db.py index d850e54e17..c463b60b26 100755 --- a/synapse/_scripts/synapse_port_db.py +++ b/synapse/_scripts/synapse_port_db.py @@ -1307,7 +1307,7 @@ def main() -> None: sqlite_config = { "name": "sqlite3", "args": { - "database": args.sqlite_database, + "database": "file:{}?mode=rw".format(args.sqlite_database), "cp_min": 1, "cp_max": 1, "check_same_thread": False, |