Postgresql added support to encrypt login passwords using SCRAM-SHA-256 with version 10, github.com/lib/pq started supporting this some time ago (see lib/pq#833).
To be able to connect to a postgresql database with a role using a SCRAM-SHA-256 encrypted password, the vendored github.com/lib/pq module needs to be upgraded.