Re: Changeset Extraction v7.9.1

From: Andres Freund <andres(at)2ndquadrant(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Craig Ringer <ringerc(at)ringerc(dot)id(dot)au>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Changeset Extraction v7.9.1
Date: 2014-03-07 13:32:01
Message-ID: 20140307133201.GB22909@awork2.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2014-03-07 10:17:21 -0300, Alvaro Herrera wrote:
> Andres Freund escribió:
>
> > fprintf(stderr,
> > - _("%s: could not identify system: got %d rows and %d fields, expected %d rows and %d fields\n"),
> > - progname, PQntuples(res), PQnfields(res), 1, 3);
> > + _("%s: could not identify system: got %d rows and %d fields, expected 1 row and 3 or more fields\n"),
> > + progname, PQntuples(res), PQnfields(res));
>
> Please don't change this. The reason these messages use %d and an extra
> printf argument is to avoid giving translators extra work when the
> number of rows or fields is changed. In these cases I suggest this:
>
> > - _("%s: could not identify system: got %d rows and %d fields, expected %d rows and %d fields\n"),
> > - progname, PQntuples(res), PQnfields(res), 1, 3);
> > + _("%s: could not identify system: got %d rows and %d fields, expected %d rows and %d or more fields\n"),
> > + progname, PQntuples(res), PQnfields(res), 1, 3);
>
> (Yes, I know the "expected 1 rows" output looks a bit silly. Since this
> is an unexpected error message anyway, I don't think that's worth
> fixing.)

I changed it to not use placeholders because I thought "or more" was
specific enough to be unlikely to be used in other places, but I don't
have a problem with continuing to use them.

Greetings,

Andres Freund

--
Andres Freund http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Craig Ringer 2014-03-07 13:33:40 Re: Row-security on updatable s.b. views
Previous Message Robert Haas 2014-03-07 13:29:14 Re: GSoC on WAL-logging hash indexes