Closed a1an77 closed 6 years ago
Thanks for the report. This sounds like a regression that is not covered by tests. I will give it a try on the weekend.
How do you call copy
function?
Can you check if you have the same issue when using https://github.com/husio/python-sqlite3-backup/pull/15 ?
I call it in an instance method with
sqlitebck.copy(sqliteFile, self.sqlite)
where self.sqlite is an in-memory instance How can I test using #15 ?
You have to pip install pointing directly at this hash, I believe it will be:
$ pip install git+git://github.com/husio/python-sqlite3-backup@b7ea6a5d6024d95c55d35f0d806144088f516edb
Then run your script as usual.
Let me know if you have any troubles.
Seems to work again now!
I have merged and released this as 1.4. Please make sure this version works for you as well and then I will close this issue.
Worked good five times in a row so I would confirm
With version 1.3 often copying a 2.6 GB database file to a memory database hangs up indefinitely (interrupted after 16 hours) instead of taking a few minutes to complete. The problem appears intermittently and I've not been able to pinpoint a specific cause. The file lies on an NFS network if that might contribute to the behaviour. There are no other processes accessing the file at the same time and the memory db is private to the thread. Using version 1.2.1 works flawlessly
PS: I suspect that for some reason the copy loop gets stuck into an SQLITE_LOCKED issue with itself, ending up sleeping indefinitely