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

Adlist comment with quotemark breaks gravity update after pull #50

Open
hartacus opened this issue Dec 3, 2023 · 0 comments
Open

Adlist comment with quotemark breaks gravity update after pull #50

hartacus opened this issue Dec 3, 2023 · 0 comments

Comments

@hartacus
Copy link

hartacus commented Dec 3, 2023

Adding a comment to an adlist that contains a quote mark or apostrophe, i.e. "Person**'**s Blocklist", breaks the gravity update on the "pull" client after the database update.

After updating the database, the pull client attempts a gravity update and receives an error:
[i] Creating new gravity databases... [✗] Unable to copy data from /etc/pihole/gravity.db to /etc/pihole/gravity.db_temp Runtime error near line 24: FOREIGN KEY constraint failed (19) [✗] Unable to create gravity database. Please try again later. If the problem persists, please contact support.

Removing the quote marks from blocklist comments on the "push" client allows the "pull" client to update gravity correctly after the next pull.

Examining the db_dump.sql file shows that the insert command attempts to escape the single quote by doubling it. This appears not to be handled well on the other end.

@hartacus hartacus changed the title Adlist comment with quotemark breaks gravity update after "pull" Adlist comment with quotemark breaks gravity update after pull Dec 3, 2023
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