SQLite Forum

error changing data - attempt to write a readonly database
Login
That's a definite diagnostic.  The problem isn't in SQLite, it's part of the permissions settings of your setup.

Take a detailed look at the permissions on the folder where you keep your database files, the database file, and journal or .shm file SQLite has created, the application doing the accessing, and anything else you think might be appropriate.

For testing, create a new special local account with minimal privileges and see whether everything works.