Description of the bug
Can't delete a volume from the WebUI.
When I choose to 'Delete volume', folder on the disk is being removed (if the 'Delete folder' flag was set), but the volume is not removed from the list in the WebUI.
Logs:
[2023-12-16 11:55:11][waitress-4][DEBUG] GET /api/volumes/43
[2023-12-16 11:55:23][waitress-9][DEBUG] DELETE /api/volumes/43
[2023-12-16 11:55:23][waitress-9][INFO] Deleting volume 43 with delete_folder set to True
[2023-12-16 11:55:23][waitress-9][INFO] Deleting volume folder of 43
[2023-12-16 11:55:23][waitress-9][DEBUG] Deleting folders from /content/comics/DC Comics/All Star Superman (2007) until /content/comics/
[2023-12-16 11:55:23][waitress-9][DEBUG] Deleting folder: /content/comics/DC Comics/All Star Superman (2007)
[2023-12-16 11:55:23][waitress-9][ERROR] Exception on /api/volumes/43 [DELETE]
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 2190, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1486, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1484, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1469, in dispatch_request
return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
File "/app/frontend/api.py", line 55, in wrapper
return method(*args, **kwargs)
File "/app/frontend/api.py", line 172, in wrapper
result = method(*args, **kwargs)
File "/app/frontend/api.py", line 418, in api_volume
volume.delete(delete_folder=delete_folder)
File "/app/backend/volumes.py", line 366, in delete
cursor.execute("DELETE FROM volumes WHERE id = ?", (self.id,))
sqlite3.OperationalError: disk I/O error
To Reproduce
Go to WebUI and open a Volume you want to remove.
Click on 'Delete'
In the 'Delete volume' pop-up select whether or not to 'Delete folder'.
Click 'Delete' button.
Expected behaviour
Volume removed from the WebUI and from the disk (if the 'Delete folder' flag was set).
Version info
Kapowarr version v1.0.0-beta-3
Python version 3.8.17.final.0
Database version 10
Database location /app/db/Kapowarr.db
Data folder /app
Kapowarr is running as a docker app on TrueNas Scale.
TrueNAS-SCALE-23.10.0.1
Kapowarr app in Scale:
The database folder is mapped to a folder (instead of a docker volume), and the folder has a non-ext4 filesystem. Check if file locking is possible for the file system. Especially because you're running TrueNAS, this could be a possibility.
The database folder has insufficient permissions. Read, write and execute permissions should be enabled for the folder and all it's files inside.
Not enough ram available for the container (highly unlikely).
Your disk could be in bad shape (unreachable sectors, corrupted, etc).
Description of the bug Can't delete a volume from the WebUI. When I choose to 'Delete volume', folder on the disk is being removed (if the 'Delete folder' flag was set), but the volume is not removed from the list in the WebUI.
Logs:
To Reproduce
Expected behaviour Volume removed from the WebUI and from the disk (if the 'Delete folder' flag was set).
Version info
Kapowarr is running as a docker app on TrueNas Scale. TrueNAS-SCALE-23.10.0.1 Kapowarr app in Scale: