Because Plasma 5 widgets need to be ported to work with Plasma 6, we need to show incompatible widgets in the WIdget Explorer separately, rather than intermixed, where users will try to use them and they won't work. If we don't do something like this, we'll get a *lot* of bug reports from frustrated users whose widgets don't work and they can't figure out why. Idea: a separate "Incompatible widgets" section in the grid view where they can live, with a little explanatory text saying that these widgets need to be ported to Plasma 6 before they'll work.
How would we detect an unported plasmoid? One idea would to see if the root is PlasmoidItem but that means we need to try loading the file or do some parsing ourselves until we encounted the root item and see if it is correct. At least we can change the error message on the desktop if it's not a PlasmoidItem to add a note that it needs porting https://invent.kde.org/frameworks/plasma-framework/-/blob/master/src/plasmaquick/appletquickitem.cpp#L530
Actually for me I the two incompatible plasmoids dont even show in the widget explorer, because they are missing the ` "KPackageStructure": "Plasma/Applet"` key in their metadata.json. Another issue is plasmoid not using metadata.json but metadata.desktop, they would also not be listed at all
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/3569
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-desktop/-/merge_requests/1853
Git commit 9aa3cf5cb7a042fbe8a1ff74ee7d719f8df315c9 by Marco Martin. Committed on 22/11/2023 at 09:46. Pushed by mart into branch 'master'. Unsupported messages in the widget explorer In the widget explorer model check if the api version is supported, and if not provide an error message in a role M +53 -1 components/shellprivate/widgetexplorer/plasmaappletitemmodel.cpp M +6 -0 components/shellprivate/widgetexplorer/plasmaappletitemmodel_p.h https://invent.kde.org/plasma/plasma-workspace/-/commit/9aa3cf5cb7a042fbe8a1ff74ee7d719f8df315c9
Git commit 4f412f65f240daf0857539bf62d6b2d69cfbf2ca by Marco Martin. Committed on 22/11/2023 at 09:46. Pushed by mart into branch 'master'. Disable unsupported entries When the plasmoid is for a different plasma api version, disable it in the widget explorer, displaying a tooltip message explaining why M +13 -1 desktoppackage/contents/explorer/AppletDelegate.qml https://invent.kde.org/plasma/plasma-desktop/-/commit/4f412f65f240daf0857539bf62d6b2d69cfbf2ca