Skip to content
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

Check: Validate appstream file FAIL #77

Closed
xiota opened this issue Sep 27, 2023 · 8 comments
Closed

Check: Validate appstream file FAIL #77

xiota opened this issue Sep 27, 2023 · 8 comments

Comments

@xiota
Copy link

xiota commented Sep 27, 2023

Attempting to build cobang 0.10.1-1 using aur/cobang.

log
==> Starting check()...
ninja: Entering directory `/home/main-builder/pkgwork/src/build'
ninja: no work to do.
1/3 Validate desktop file   OK              0.01s
2/3 Validate schema file    OK              0.01s
3/3 Validate appstream file FAIL            0.07s   exit status 1
>>> MALLOC_PERTURB_=217 /usr/bin/appstream-util validate-relax /home/main-builder/pkgwork/src/build/../CoBang-0.10.1/data/vn.hoabinh.quan.CoBang.appdata.xml
――――――――――――――――――――――――――――――――――――― ✀  ―――――――――――――――――――――――――――――――――――――
stdout:
/home/main-builder/pkgwork/src/build/../CoBang-0.10.1/data/vn.hoabinh.quan.CoBang.appdata.xml: FAILED:
• file-invalid          : <screenshot> url is a zero length file [https://i.imgur.com/K3TU9bm.png]
• file-invalid          : <screenshot> url is a zero length file [https://i.imgur.com/bIV57cV.png]
• file-invalid          : <screenshot> url is a zero length file [https://i.imgur.com/ldynPU6.png]
• file-invalid          : <screenshot> url is a zero length file [https://i.imgur.com/aORgQKj.png]
• file-invalid          : <screenshot> url is a zero length file [https://i.imgur.com/MyH9CEC.png]
stderr:
Validation of files failed
――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――


Summary of Failures:

3/3 Validate appstream file FAIL            0.07s   exit status 1

Ok:                 2
Expected Fail:      0
Fail:               1
Unexpected Pass:    0
Skipped:            0
Timeout:            0

Full log written to /home/main-builder/pkgwork/src/build/meson-logs/testlog.txt
==> ERROR: A failure occurred in check().
@hongquan
Copy link
Owner

hongquan commented Oct 3, 2023

Maybe your build environment blocks Internet access? It said

url is a zero length file [https://i.imgur.com/K3TU9bm.png]

But that URL is actually valid, you can check it yourself.

@xiota
Copy link
Author

xiota commented Oct 3, 2023

Internet access was okay because build server downloads fresh sources prior to building. Seems like was probably a temporary Imgur issue because successfully builds now. But why are those files on Imgur instead of in the git repo and source tarball? Imgur can go down or refuse connections for maintenance, captcha checks, or other reasons.

@hongquan
Copy link
Owner

hongquan commented Oct 3, 2023

Because before your report, there was no issue with Imgur accessibility, and I don't want to store binary files in Git repo.

@xiota
Copy link
Author

xiota commented Oct 3, 2023

I think binaries are fine / common for screenshots, icons, and some other types of files. If you decide not to add them to the repo, I'll ask the aur maintainer to add them to the package.

@hongquan
Copy link
Owner

hongquan commented Oct 3, 2023

I will move the screenshots to Git repo.

@hongquan
Copy link
Owner

hongquan commented Oct 3, 2023

I planned to move the screenshots to Git repo, but then I don't know how to specify the image location in the appdata file. Its specs says that:

The value of the <image/> tag is a direct URL to a screenshot uploaded to a public location on the web.

So it seems that we still have to use https://... URL here, and using https://github.com is not different than using Imgur service.

@xiota
Copy link
Author

xiota commented Oct 3, 2023

I will move the screenshots to Git repo.

Would be appreciated.

I don't know how to specify the image location

Something like: https://raw.githubusercontent.com/hongquan/CoBang/main/LICENSE.txt

Even if the link is not changed, I think it would be beneficial to have a backup of the images in the git repo.

Is there a way to verify the appdata file without downloading the links?

using https://github.com is not different than using Imgur service.

Using a single site / service is less prone to failure than using more. To even access the source in the first place, Github has to be working. So it's less likely to fail during build than Imgur. Also, from personal use, Github uptime is much better than Imgur, which frequently goes down for "maintenance".

@hongquan
Copy link
Owner

hongquan commented Oct 5, 2023

I already move screenshots to Git repo.

@hongquan hongquan closed this as completed Oct 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants