It turns out the "encoding" issue I've been chasing where PostgreSQL says "invalid byte sequence for encoding" when trying to do a query, probably isn't anything to do with incorrect encoding...
My latest theory is that something about the way the query is executed isn't garbage collector safe, and when the garbage collector runs, the memory regions containing the parameters get altered...
This theory at least explains why I see this issue intermittently.
So... after 3 days, it still hadn't finished. I gave up, stopped the DELETE, added an index on a table referencing the table I was deleting from, and then it finished in a few minutes...
It's the "Trigger for constraint" bit that apparently was taking forever.
Actually made it through a pretty big refactor of how the Guix Data Service handles database connections for HTTP requests: https://git.savannah.gnu.org/cgit/guix/data-service.git/commit/?id=c3c9c07f9a208633882a21004d30c5ee29026cb1
There should be less chance of the server being slow handling requests now, and some requests should even be faster due to extra parallelism.
I'm pretty sure I must have broken something somewhere though...
“Improve Internationalization Support for the #Guix Data Service”:
Seems like I've actually managed to build some substitutes! #guix
Got a first review for my 10-year-reproducibility-challenge submission: https://github.com/ReScience/submissions/issues/32#issuecomment-633739558
Highlight: “The current code is based on Scheme, a variant of LISP, which is notoriously very readable, nearly as it were a text in english.” See? :-)
Living in London
Interested in Free Software, Badminton, Bouldering and cats.
The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!