Closed martinburchell closed 1 year ago
Thanks; looks great.
chit.rst
).Thinking about potential version incompatibility:
minimumServerVersion()
in chit.h
/chit.cpp
. The old task should upload fine structurally (the missing Q16 won't cause a problem) but the validators would later complain via field_contents_valid()
. I don't think adding this will cause much of a problem, so I've added it. (The task would also have missing strings if it fetched from an old server.) Say if you think that's wrong!minimum_client_version
in chit.py
just in case. Reasonable? This will, via client_api.ensure_valid_table_name()
, make the client be upgraded before it can upload.I also looked at trying to fix the clazy linter comments, e.g. about string literals, but some of the suggested performance fixes for Qt5 then instantly fall foul of warnings for Qt6. For example:
const QString spacer = " "; // bad: QString(const char*) being called [clazy-qstring-allocations]
const QString spacer = QStringLiteral(" "); // good
as per https://doc.qt.io/qt-5/qstring.html#more-efficient-string-construction and https://github.com/KDE/clazy/blob/master/docs/checks/README-qstring-allocations.md, but
const QString suffix = ""; // bad: QString(const char*) being called [clazy-qstring-allocations]
const QString suffix = QStringLiteral(""); // bad: Use an empty QLatin1String instead of an empty QStringLiteral [clazy-empty-qstringliteral]
const QString suffix = QLatin1String(""); // bad: QLatin1Char or QLatin1String is being called [clazy-qt6-qlating1stringchar-to-u]
so presumably the best thing is to move directly to Qt6, e.g. this sort of framework: https://doc.qt.io/qt-6/qt-literals-stringliterals.html ?
Your changes for version compatibility seem entirely reasonable to me.
so presumably the best thing is to move directly to Qt6, e.g. this sort of framework: https://doc.qt.io/qt-6/qt-literals-stringliterals.html ?
That appears to be new in Qt6.4 which isn't LTS. I'm currently targeting 6.2, which is LTS.
I've updated CHI-T to add the extra response and remove Q16. Closes #269