Renewal fails in cron, works on CLI

So Certbot was installed using the PPA, but two of the Certbot packages are quite out of date and out of sync with the others.

Plus, python3-certbot-dns-digitalocean isn’t installed at all, which means it must be installed some other way, and its version might also be out of sync.

I guess you should upgrade your packages, apt install python3-certbot-dns-digitalocean, and hunt down the other copy of the DigitalOcean plugin and delete it (carefully).

(The python3-certbot-dns-digitalocean package is version 0.23.0, but it’s supposed to be. The plugin hasn’t changed recently and the PPA is managed in a compatible way.)