sqlite error "attempt to write a readonly database" when databse is not readonly

Bug #1719716 reported by yjmsyzne
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
The Mnemosyne Project
Invalid
Undecided
Unassigned

Bug Description

I run Mnemosyne inside a syncthing container. Initially the setup was working fine, but after a few weeks of use I am getting errors often when I try to save or load the database.

```
Traceback (innermost last):
  File "/usr/local/bin/mnemosyne", line 4, in <module>
    __import__('pkg_resources').run_script('Mnemosyne==2.5', 'mnemosyne')
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 742, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1503, in run_script
    exec(code, namespace, namespace)
  File "/usr/local/lib/python3.5/dist-packages/Mnemosyne-2.5-py3.5.egg/EGG-INFO/scripts/mnemosyne", line 273, in <module>
    mnemosyne.finalise()
  File "/usr/local/lib/python3.5/dist-packages/Mnemosyne-2.5-py3.5.egg/mnemosyne/libmnemosyne/__init__.py", line 385, in finalise
    self.log().saved_database()
  File "/usr/local/lib/python3.5/dist-packages/Mnemosyne-2.5-py3.5.egg/mnemosyne/libmnemosyne/loggers/database_logger.py", line 56, in saved_database
    scheduled_count, non_memorised_count, active_count)
  File "/usr/local/lib/python3.5/dist-packages/Mnemosyne-2.5-py3.5.egg/mnemosyne/libmnemosyne/databases/SQLite_logging.py", line 58, in log_saved_database
    scheduled_count, non_memorised_count, active_count))
  File "/usr/local/lib/python3.5/dist-packages/Mnemosyne-2.5-py3.5.egg/mnemosyne/libmnemosyne/databases/_sqlite3.py", line 72, in execute
    self._cursor = self.connection.execute(sql, *args)
 sqlite3.OperationalError: attempt to write a readonly database
```

The database is not readonly, and when I try the operation again it normally works fine.

Is this just an inherent problem with running Mnemosyne inside syncthing or is it something that could be worked around or fixed?

Revision history for this message
Peter Bienstman (peter-bienstman) wrote :

I've not seen this before, so unless you can reproduce it outside of syncthing, I'm afraid there not much I can do about it...

Changed in mnemosyne-proj:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.