New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error generating compose data with localized metadata_license
#433
Comments
|
Example: https://appstream.alpinelinux.org/html/edge/community/issues/gnome-terminal.html And the metainfo file: org.gnome.Terminal.Nautilus.metainfo.txt I had to rename it to a txt because github would not allow me to upload it... |
|
Ooof, where do I even start?
So the outcome of rejecting this component is correct, the data is invalid this way - the error of the compose tool could be better, but that tool should also show validation results. And those are extremely explicit: So, not sure if we can complain even more loudly here that this input data is bad... :-D |
|
Oh well, yeah, that looks bad. Thank you for the information, I guess I will have to follow on this upstream, but seem to be an issue with more projects :( |
metainfo_licensemetadata_license
|
From a quick look at the GNOME Terminal source code, I think the only reason why the proper ITS rules aren't applied is that the input data file is called From a quick check, no ITS rule takes into account that the file suffix may be different, therefore I think the proper way to address this is to just drop the |
|
Thank you for looking into this.
The whole of GNOME uses the prefix in the pre-processing (sometimes even a double prefix |
|
I wonder if this is because of the made-up namespace that gnome-terminal seems to be using while no other app I ever looked at does that... |
|
Yes, you're right! I tried removing those tags, and regenerating the PO
files, and the one that actually fixes the generation is
xmlns="https://specifications.freedesktop.org/metainfo/1.0". Removing
it creates the correct po files for me. The others seem to have no
impact. I guess I will open an issue upstream.
Thanks a lot for your expertise! I am not sure I would have had any
chance of getting this one right.
…On Tue, 2022-09-20 at 17:34 -0700, Matthias Klumpp wrote:
I wonder if this is because of the made-up namespace that gnome-
terminal seems to be using while no other app I ever looked at does
that...
I wonder whether the correct ITS rule will be applied if you just
delete the xmlns:its="http://www.w3.org/2005/11/its" line in all
metainfo XML files...
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
|
I remember that the gnome-terminal guy insisted on this having a namespace for some reason, even though nobody else adds one and having one isn't even needed. |
|
Seems like it's at least work-arounded in stable versions :) |
In the appstream-generator in alpine, we are currently seeing some programs fail with this error:
The reason seems to be that while parsing the metainfo files, in the
as_component_load_from_xmlfile, all themetadata_licensetags are processed, regardless of its localization. Therefore, some localized metainfo file like the following:will end up with the localized version (because it is the last one) as the
metadata_license.I can think of different solutions to this, from only processing non-localized
metadata_licenseentries to verifying the correctness of the entered license inas_component_set_metadata_license. However, I am not sure of the other implications it might have, so I decided to open an issue and wait for guidance :)The text was updated successfully, but these errors were encountered: