D21154: Automatically run pg_upgrade when major PostgreSQL upgrade is detected
Sandro Knauß
noreply at phabricator.kde.org
Tue May 14 23:53:16 BST 2019
knauss added inline comments.
INLINE COMMENTS
> dbconfigpostgresql.cpp:215
> + // Get the major version from major.minor
> + QRegularExpression re(QStringLiteral("\\(PostgreSQL\\) ([0-9]+).[0-9]+"));
> + const auto match = re.match(output);
really "\\(" ? this is different in different languages, did you tested your regex?
> dvratil wrote in dbconfigpostgresql.cpp:254
> Thanks.
>
> Tha main difference between this and the lookup in `init()` is that here we are looking for a specific version of Postgres, while in `init()` we are looking for the newest one (without knowing what version it is)
I understand the difference, but in` init() ` you ONLY check `/usr/lib/postgresql/*/bin` and not
`/usr/lib64/pgsql/postgresql-*/bin` and `/usr/lib/pgsql/postgresql-*/bin`. I would argue that those dictionaries should be searched in `init()` too. Because also for other Distributions the new postgres version won't be available in normal search path.Otherwise we will end up in situations, where we fix one place and add a new Distribution style and forget in the other function et visa versa.
REPOSITORY
R165 Akonadi
REVISION DETAIL
https://phabricator.kde.org/D21154
To: dvratil, #kde_pim
Cc: knauss, kde-pim, dvasin, rodsevich, winterz, vkrause, mlaurent, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20190514/f53cb5e1/attachment.html>
More information about the kde-pim
mailing list