I found the problem: Eclipse showed the dependencies properly, but as it seemed the class was not really present, I tried to run it manually, so when I executed:
mvn clean install
I got this error from Maven
error reading /home/pablo/.m2/repository/org/postgresql/postgresql/42.2.5/postgresql-42.2.5.jar; invalid LOC header (bad signature)
So the error was caused by Maven downloading a corrupt version of the jar.
Deleting it to force a new download fixed the issue.