https://github.com/ximion/appstream/issues/183 saw the introduction of extra query arguments through which alternative (legacy) ids may be communicated. So `appstream:org.kde.krita?alt=krita.desktop` will allow modern systems to use the modern id while old systems can find it by alt id. AppStreamUtils::appstreamId seems to not yet implement this. I also want to note that when updating the logic you should take care to keep ignoring invalid inputs. e.g. `appstream:org.kde.krita?alt=krita.desktop&randomparam=yes` should ignore randomparam rather than stumble over it (this is to ensure future updates to the URI format will not break assumptions)
Git commit 9101a2d299a235e6b478792e246e4660f3586317 by Aleix Pol. Committed on 17/01/2020 at 14:56. Pushed by apol into branch 'Plasma/5.18'. appstream: support appstream uri alt ids M +9 -2 libdiscover/appstream/AppStreamUtils.cpp M +1 -1 libdiscover/appstream/AppStreamUtils.h M +6 -6 libdiscover/backends/FlatpakBackend/FlatpakBackend.cpp M +10 -7 libdiscover/backends/PackageKitBackend/PackageKitBackend.cpp M +59 -38 libdiscover/backends/SnapBackend/SnapBackend.cpp M +7 -0 libdiscover/backends/SnapBackend/SnapBackend.h https://commits.kde.org/discover/9101a2d299a235e6b478792e246e4660f3586317