Details
-
Bug
-
Resolution: Invalid
-
Not Evaluated
-
None
-
6.8.2
-
None
-
Linux, X11, self-built Qt
Description
$ qdbusxml2cpp -m -i person.h -p peopleserver_interface com.kdab.PeopleServerAPI.xml com.kdab.PeopleServerAPI.xml:5:8: error: Invalid D-Bus type signature 'a{ssss}' found while parsing introspection
And yet there's an annotation that says what to do about that custom type:
<arg type="a{ssss}" direction="out"/> <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QVector<Person>"/>
And if I comment out the call to QDBusUtil::isValidSingleSignature in QDBusXmlParser::parseArg (which leads to that error), everything works fine, the generated code is correct and builds, the app works at runtime, it's all good.
So this is basically a false positive, qdbusxml2cpp being too strict for no good reason.
Qt5's qdbusxml2cpp worked and didn't even output an error/warning because qDBusParserError failed to say anything (it was a qCDebug using an area where debug msgs were off by default), and because it would continue and exit with code 0 after that.
Qt6's qdbusxml2cpp has this new code:
if (reporter.hadErrors())
exit(1);
So overall, a silent qDebug in Qt5 got upgraded to a qFatal in Qt-6.7, due to "qdbusxml2cpp: Improve error reporting" https://codereview.qt-project.org/c/qt/qtbase/+/487481