This is kind of a follow-on from https://bugzilla.redhat.com/show_bug.cgi?id=2011322 . We 'fixed' that bug by configuring plasma-discover to never use appstream's system cache, but that's kind of a workaround rather than a fix. I have a few questions and potential issues with appstream caching as follow-ups from that bug, but this is one thing that obviously seems to be wrong: if you boot a Fedora live image, or a system installed from one, it will have a small /var/cache/app-info/cache/en_US.cache file (always en_US, even if you pick another locale at install time). It is only 167936 bytes in size, whereas a cache file generated after install is over 20000000 bytes. It seems most likely the file is generated when we install packages to produce the live image, by appstream's %posttrans: /usr/bin/appstreamcli refresh --force >& /dev/null ||: but I don't know why it winds up being so tiny (and likely empty). I don't think it's because it needs internet access (there is no internet access during live image builds), because if I move the cache file and run `unshare -n appstreamcli refresh --force` (which prevents the process from using the network), I get a full-size file. We could just strip this file at the end of live image generation, I guess, but that seems kind of inelegant. It'd be nicer to figure out why this is happening and either prevent it entirely (so the cache will be built the first time anything tries to use it after install), or have it built properly...
hmm, well, this is interesting...it's actually only KDE lives that have the tiny cache. Workstation lives have an apparently full-sized cache. I'll attach the cache file from a KDE live to this bug for reference. It's not actually empty, by the looks of it (I ran strings on it and it clearly contains appstream data), but clearly missing a lot of stuff for some reason.
Created attachment 1837428 [details] /var/cache/app-info/cache/en_US.cache from Fedora 35 RC1 KDE live image
So this has become more urgent again, as our F35-era workaround for https://bugzilla.redhat.com/show_bug.cgi?id=2011322 doesn't work any more after appstream changes upstream and has been disabled, and the bug seems to have come back - see https://bugzilla.redhat.com/show_bug.cgi?id=2057531 . I checked recent F36/Rawhide images and this does still seem to be the case, though the cache file names have changed slightly. There are now two files in /var/cache/app-info/cache/ , en_US-local-metainfo.xb and en_US-os-catalog.xb . On a KDE image from January the local-metainfo file is 457360 bytes, and the os-catalog file is 53123 bytes. On a GNOME image from February the local-metainfo file is 662041 bytes, and the os-catalog file is 11752242 bytes. So the big difference is the os-catalog file, which is almost empty on KDE but over 11M on GNOME. I'm still not sure why this difference exists. I'm assuming the cache is generated by appstream's %posttrans script when the live image is built, but both Workstation and KDE live image builds include the same appstream-related packages (plus appstream-qt on the KDE image), so I'm not sure what the difference might be that causes the cache generation to apparently not work properly when building the KDE image. I'm gonna test removing the redirect to /dev/null from the scriptlet for now and see if that gives us any useful error messages.
Hum. I just checked the latest F36 nightly KDE ISO, and the os-catalog cache on that one is 11752242 bytes, the same as on the Workstation ISO I checked. And indeed I couldn't reproduce the 2011322/2057531 bug with that ISO. Not sure if something changed, or that ISO just got lucky...
This message is a reminder that Fedora Linux 35 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora Linux 35 on 2022-12-13. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a 'version' of '35'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, change the 'version' to a later Fedora Linux version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora Linux 35 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora Linux, you are encouraged to change the 'version' to a later version prior to this bug being closed.
checking an F37 live from mid-July (all I had on hand), there is no /var/cache/app-info/cache in it. On an ls -R , /var/cache/app-info is basically empty (a few directories, each containing no files). So this...probably isn't a problem any more. Let's let it die with EOL.
Fedora Linux 35 entered end-of-life (EOL) status on 2022-12-13. Fedora Linux 35 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora Linux please feel free to reopen this bug against that version. Note that the version field may be hidden. Click the "Show advanced fields" button if you do not see the version field. If you are unable to reopen this bug, please file a new report against an active release. Thank you for reporting this bug and we are sorry it could not be fixed.