The thread was about random errors which occurred when running
sudo certbot renew --cert-name MYDOMAIN.TLD --dry-run
The thread was closed without solution. See original thread. So I have to open a new thread to be able to post the solution.
I continued to monitor certbot's behavior using the script provided in the original thread. The bug was present the whole time certbot 2.x was current. The bug disappeared after the snap demon updated certbot to version 3.0.1. My conclusion from this is that it was probably a hidden bug in certbot that was fixed by the new main release.