Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

backup-compact failing #245

Open
GamerSg opened this issue May 27, 2021 · 1 comment
Open

backup-compact failing #245

GamerSg opened this issue May 27, 2021 · 1 comment

Comments

@GamerSg
Copy link

GamerSg commented May 27, 2021

I usually run backup-compact occasionally and it works fine.
Today, I tried running backup-compact and got this error:

I tried using backup-cli to create a new snapshot but it doesn't work because the plugin is looking for the current version of the backup.
Is there any way where i can create a new snapshot?

{
   "code": -32600,
   "message": "Error while processing backup-compact: UNIQUE constraint failed: payments.payment_hash, payments.partid",
   "traceback": "Traceback (most recent call last):\n  File \"/home/pi/.local/lib/python3.7/site-packages/pyln/client/plugin.py\", line 621, in _dispatch_request\n    result = self._exec_func(method.func, request)\n  File \"/home/pi/.local/lib/python3.7/site-packages/pyln/client/plugin.py\", line 603, in _exec_func\n    return func(*ba.args, **ba.kwargs)\n  File \"/home/pi/exthd/Code/plugins/backup/backup.py\", line 83, in compact\n    return plugin.backend.compact()\n  File \"/home/pi/exthd/Code/plugins/backup/filebackend.py\", line 155, in compact\n    self._restore_transaction(change.transaction)\n  File \"/home/pi/exthd/Code/plugins/backup/backend.py\", line 100, in _restore_transaction\n    cur.execute(q)\nsqlite3.IntegrityError: UNIQUE constraint failed: payments.payment_hash, payments.partid\n"
}
@GamerSg
Copy link
Author

GamerSg commented May 28, 2021

I managed to create a new snapshot.

However, today i received another failure.
It is kind of worrying, is it possible that the backup plugin/hook is buggy? Or could this be a hardware issue on my end?

{
   "code": -32600,
   "message": "Error while processing backup-compact: FOREIGN KEY constraint failed",
   "traceback": "Traceback (most recent call last):\n  File \"/home/pi/.local/lib/python3.7/site-packages/pyln/client/plugin.py\", line 621, in _dispatch_request\n    result = self._exec_func(method.func, request)\n  File \"/home/pi/.local/lib/python3.7/site-packages/pyln/client/plugin.py\", line 603, in _exec_func\n    return func(*ba.args, **ba.kwargs)\n  File \"/home/pi/exthd/Code/plugins/backup/backup.py\", line 83, in compact\n    return plugin.backend.compact()\n  File \"/home/pi/exthd/Code/plugins/backup/filebackend.py\", line 155, in compact\n    self._restore_transaction(change.transaction)\n  File \"/home/pi/exthd/Code/plugins/backup/backend.py\", line 100, in _restore_transaction\n    cur.execute(q)\nsqlite3.IntegrityError: FOREIGN KEY constraint failed\n"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant