aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2020-06-09 15:42:01 +0200
committerUlf Hermann <ulf.hermann@qt.io>2020-06-17 17:09:33 +0200
commit9d40cc4b63d633c3d657fd78cc5d2ca37a5de3b7 (patch)
tree15adcf650042812719d6cf7416a63eeb876631c0 /src/qml
parente6107060fe5a1dc898466330c9b4f61d7f804576 (diff)
Drop the "plugin cannot be loaded" extension to error messages
This message adds very little extra value, and it complicates the tests that check for specific errors. Change-Id: I58553a8cbc56c3333c8e9815518cca5fa01fdde1 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qml')
-rw-r--r--src/qml/qml/qqmlimport.cpp16
1 files changed, 0 insertions, 16 deletions
diff --git a/src/qml/qml/qqmlimport.cpp b/src/qml/qml/qqmlimport.cpp
index ad7cda2145..85af8c5beb 100644
--- a/src/qml/qml/qqmlimport.cpp
+++ b/src/qml/qml/qqmlimport.cpp
@@ -1200,21 +1200,6 @@ bool QQmlImportsPrivate::importExtension(const QString &qmldirFilePath,
int dynamicPluginsFound = 0;
int staticPluginsFound = 0;
- auto handleErrors = [&]() {
- if (errors) {
- // XXX TODO: should we leave the import plugin error alone?
- // Here, we pop it off the top and coalesce it into this error's message.
- // The reason is that the lower level may add url and line/column numbering information.
- QQmlError error;
- error.setDescription(
- QQmlImportDatabase::tr(
- "plugin cannot be loaded for module \"%1\": %2")
- .arg(uri, errors->takeFirst().description()));
- error.setUrl(QUrl::fromLocalFile(qmldirFilePath));
- errors->prepend(error);
- }
- };
-
const auto qmldirPlugins = qmldir.plugins();
for (const QQmlDirParser::Plugin &plugin : qmldirPlugins) {
const QString resolvedFilePath = database->resolvePlugin(
@@ -1226,7 +1211,6 @@ bool QQmlImportsPrivate::importExtension(const QString &qmldirFilePath,
++dynamicPluginsFound;
if (!database->importDynamicPlugin(
resolvedFilePath, uri, typeNamespace, version, plugin.optional, errors)) {
- handleErrors();
return false;
}
}