Re: pg_upgrade --check fails to warn about abstime
Suraj Kharage <suraj.kharage@enterprisedb.com>
From: Suraj Kharage <suraj.kharage@enterprisedb.com>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Pg Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-09-21T06:35:43Z
Lists: pgsql-hackers
Thanks, Alvaro, for working on this. The patch looks good to me. + * similar to the above, but for types that were removed in 12. Comment can start with a capital letter. Also, We need to backport the same, right? On Wed, Sep 20, 2023 at 10:24 PM Alvaro Herrera <alvherre@alvh.no-ip.org> wrote: > I got a complaint that pg_upgrade --check fails to raise red flags when > the source database contains type abstime when upgrading from pg11. The > type (along with reltime and tinterval) was removed by pg12. > > > In passing, while testing this, I noticed that the translation > infrastructure in pg_upgrade/util.c is broken: we do have the messages > in the translation catalog, but the translations for the messages from > prep_status are never displayed. So I made the quick hack of adding _() > around the fmt, and this was the result: > > Verificando Consistencia en Vivo en el Servidor Antiguo > ------------------------------------------------------- > Verificando las versiones de los clústers éxito > Verificando que el usuario de base de datos es el usuario de > instalaciónéxito > Verificando los parámetros de conexión de bases de datos éxito > Verificando transacciones preparadas éxito > Verificando tipos compuestos definidos por el sistema en tablas de > usuarioéxito > Verificando tipos de datos reg* en datos de usuario éxito > Verificando contrib/isn con discordancia en mecanismo de paso de > bigintéxito > Checking for incompatible "aclitem" data type in user tables éxito > Checking for removed "abstime" data type in user tables éxito > Checking for removed "reltime" data type in user tables éxito > Checking for removed "tinterval" data type in user tables éxito > Verificando conversiones de codificación definidas por el usuarioéxito > Verificando operadores postfix definidos por el usuario éxito > Verificando funciones polimórficas incompatibles éxito > Verificando tablas WITH OIDS éxito > Verificando columnas de usuario del tipo «sql_identifier» éxito > Verificando la presencia de las bibliotecas requeridas éxito > Verificando que el usuario de base de datos es el usuario de > instalaciónéxito > Verificando transacciones preparadas éxito > Verificando los directorios de tablespaces para el nuevo clústeréxito > > Note how nicely they line up ... not. There is some code that claims to > do this correctly, but apparently it counts bytes, not characters, and > also it appears to be measuring the original rather than the > translation. > > I think we're trimming the strings in the wrong places. We need to > apply _() to the originals, not the trimmed ones. Anyway, clearly > nobody has looked at this very much. > > -- > Álvaro Herrera PostgreSQL Developer — > https://www.EnterpriseDB.com/ > "We’ve narrowed the problem down to the customer’s pants being in a > situation > of vigorous combustion" (Robert Haas, Postgres expert extraordinaire) > -- -- Thanks & Regards, Suraj kharage, edbpostgres.com
Commits
-
pg_upgrade: check for types removed in pg12
- fb9ddd0fafea 16.1 landed
- 8845d8597d77 15.5 landed
- 26c291a15243 14.10 landed
- d3946c4f622f 13.13 landed
- af9f6cd1ddfa 12.17 landed
- 2e3dc8c14811 17.0 landed