diff --git a/scripts/match_filenames.py b/scripts/match_filenames.py index fd310f9..fa1c724 100755 --- a/scripts/match_filenames.py +++ b/scripts/match_filenames.py @@ -281,7 +281,9 @@ def load_movies(database_file: Path) -> list[Movie]: f"Database file does not exist: {database_file}" ) - with sqlite3.connect(database_file) as connection: + database_uri = f"{database_file.resolve().as_uri()}?mode=ro" + + with sqlite3.connect(database_uri, uri=True) as connection: connection.row_factory = sqlite3.Row movie_rows = connection.execute(