pymysql.err.OperationalError when creating a new app and site

That’s UNIX socket.
What do you get with: ps xa | grep mysqld
Maybe you should try on Debian 10 or 11 installation, I solved installation problems with this tutorial: [Tutorial] How to 'manually' install ERPNext v13.11 Production on Debian 10 (w/SSL cert)