go-appimage: AppStream validator gives wrong results and can't be disabled

Running appstreamcli validate on this file

org.inkscape.Inkscape.appdata.xml

says that it is valid:

✔ Validation was successful: pedantic: 1

But when packaging it using appimagetool-817-x86_64.AppImage, it complains about errors:

Trying to validate AppStream information with the appstreamcli tool
ERROR appstreamcli: exit status 3
ERROR: AppStream metainfo file file contains errors. Please fix them. Please see https://www.freedesktop.org/software/appstream/docs/chap-Quickstart.html#sect-Quickstart-DesktopApps
org.inkscape.Inkscape.appdata.xml
  I: org.inkscape.Inkscape:8: unknown-tag developer
  W: org.inkscape.Inkscape:247: url-invalid-type vcs-browser
  W: org.inkscape.Inkscape:248: url-invalid-type contribute

In particular, it says <developer/> is an unknown tag, then provides a link to a page explicitly documenting it.

Is the bundled appstreamcli out of date, or is it genuinely supposed to be checking something different?

If not, then there should at least be a way to disable this validation check, since it’s currently hard-coded to true.

About this issue

  • Original URL
  • State: open
  • Created 3 years ago
  • Comments: 26 (11 by maintainers)

Commits related to this issue

Most upvoted comments

Discovered this yesterday

The version of appstreamcli you bundle will segfault on a metainfo having a <screenshot> entry containing only an <image> entry (that is, missing the <caption> entry).

This issue wasn’t obvious, as newer versions of appstreamcli didn’t have any issue with this, not even emitting a warning.

This issue has been open for 8 months, with the true fix (updating the validator) indefinitely stalled (PR). The commenter above has even forked the project just to disable the validator, while Inkscape is using a grotesque hack to get around it. Surely an -n disable switch is reasonable at this point? Or an option to override the validator with the system one?

This is before we even get to the issue of offline building, or whether go-appimage should silently be making network requests in a way that cannot be disabled.

Passing --no-net to appstreamcli unconditionally probably makes sense, or only allow network access when the network is confirmed working and URL validation is desired.

This issue has been open for 8 months, with the true fix (updating the validator) indefinitely stalled (PR). The commenter above has even forked the project just to disable the validator, while Inkscape is using a grotesque hack to get around it. Surely an -n disable switch is reasonable at this point? Or an option to override the validator with the system one?

Hey I took a look at the Inkscape appimage script

If the grotesque hack is using appimagekit for the second step, a better solution would be this appimagetool instead since it uses zstd comp and the static runtime by default, aka you would get the same appimage as if go-appimage had made the second step. And it has the -n option which disables appstream validation.

Since which version is --no-net supported?

Pretty much forever, since validate existed. There’s no version without it.

Currently we are simply calling it the “static runtime”. But maybe there will be one day a type 3 (or version 3 of the spec) that will require the runtime to be static (= not require libfuse).

I’ve built more than 60 AppImages in my repositories and now I switched all my workflows to this new fantastic version of appimagetool, so thanks @probonopd !

I had the AppStream error only in five (5) of them, but I’ve solved by removing the content of /usr/share/metainfo