When I run this query from psql shell everything works fine:
ALTER ROLE postgres WITH ENCRYPTED PASSWORD 'somePassword';
but when I try exactly the same query from python (with psycopg2 package) authentication fails when I try to connect with the password.
what can go wrong? I tried simple passwords with no non-ansi characters etc...