I'm not sure whether there's a way to fix this that doesn't break other cases. We could retrieve the pg_database.datcollate string from the remote, but that doesn't necessarily match up with any collation name we know about locally. One pretty common failure mode would be that the datcollate string isn't a canonical spelling (eg, "en_US.UTF-8" where the name we know about is "en_US.utf8"). In general, datcollate is handled through other code paths than collation names, so it might easily be that it doesn't match anything in the remote's pg_collation catalog either :-(.
This is where we got stuck as well (+David who did a lot of digging on this issue). Hence submitting the discovery without our half-baked patch.
We had difficulty finding the place in the code were LC_COLLATE gets recombobulated into a recognized collation.