Skip to content

Build Runtime and test it#344

Open
sergio-costas wants to merge 8 commits intoubuntu:gnome-46-2404-sdkfrom
sergio-costas:build-runtime
Open

Build Runtime and test it#344
sergio-costas wants to merge 8 commits intoubuntu:gnome-46-2404-sdkfrom
sergio-costas:build-runtime

Conversation

@sergio-costas
Copy link
Copy Markdown
Contributor

@sergio-costas sergio-costas commented Jan 19, 2026

This PR builds the runtime against a new SDK, and tests it against several snaps. Specifically, it tests:

  • firefox
  • thunderbird
  • darktable
  • cheese
  • gimp
  • gnome-calculator
  • gnome-system-monitor
  • gnome-text-editor
  • evince
  • kicad
  • chromium
  • shotwell
  • telegram
  • mattermost

It uses YARF OCR capabilities to detect that the application has been launched correctly. After it detects it, it waits five seconds and test again, to ensure that it is still working (thus to avoid the case where the window does appear but the application crashes immediately).

If a test fails, it uploads an artifact with the YARF logs, to check if it's a test problem or a PR problem.

@sergio-costas sergio-costas marked this pull request as draft January 21, 2026 09:02
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
@3v1n0
Copy link
Copy Markdown
Contributor

3v1n0 commented Mar 4, 2026

Is this good to go now?

A part squashing the last commit with the initial one, I feel that we're good here.

@sergio-costas
Copy link
Copy Markdown
Contributor Author

I still want to add the tests themselves: to install several snaps, launch them, and ensure that they run instead of failing.

@3v1n0
Copy link
Copy Markdown
Contributor

3v1n0 commented Mar 4, 2026

I still want to add the tests themselves: to install several snaps, launch them, and ensure that they run instead of failing.

Fair.. Well, can we just add some very dummy test for now (just ensure that some simple app starts and closes without failing)?

So we can unblock #294 or can we land that without this?

Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml
@sergio-costas sergio-costas marked this pull request as ready for review April 8, 2026 17:40
@sergio-costas sergio-costas requested a review from 3v1n0 April 8, 2026 17:40
@sergio-costas
Copy link
Copy Markdown
Contributor Author

@3v1n0 I squashed all the commits, and it's ready for review.

Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml
Copy link
Copy Markdown
Contributor

@3v1n0 3v1n0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this and lots of tests.

There are some things to re-enable, but first I've some cleanups to suggest.

Also, checking the logs, maybe it's also worth to install the xdg-desktop-portal (gtk or gnome)? As they are used by some snaps and in general it's a requirement component to get the snaps working

Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
@3v1n0
Copy link
Copy Markdown
Contributor

3v1n0 commented Apr 9, 2026

Maybe temporarily revert 09aca1c :)

Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
Comment thread .github/workflows/build.yml Outdated
@sergio-costas sergio-costas force-pushed the build-runtime branch 2 times, most recently from 397004a to 9bb389a Compare April 10, 2026 10:03
@sergio-costas
Copy link
Copy Markdown
Contributor Author

@3v1n0 mattermost was updated this last friday, and now it doesn't launch. It returns a GPU problem. Any idea?

Comment thread .github/workflows/test_script.sh
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would use a clearer name what this is about

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you propose, instead?

Comment thread .github/workflows/test_script.sh Outdated
Comment thread .github/workflows/test_script.sh Outdated
Comment thread .github/workflows/build.yml Outdated
@3v1n0
Copy link
Copy Markdown
Contributor

3v1n0 commented Apr 13, 2026

I would still like to launch a proper dbus session, or even the whole systemd --user session where we test, so that we actually have the portals running as we are getting currently:

(evince:7698): Gdk-WARNING **: 11:53:00.832: Failed to read portal settings: GDBus.Error:org.freedesktop.DBus.Error.UnknownMethod: No such interface “org.freedesktop.portal.Settings” on object at path /org/freedesktop/portal/desktop

@sergio-costas
Copy link
Copy Markdown
Contributor Author

I would still like to launch a proper dbus session, or even the whole systemd --user session where we test, so that we actually have the portals running as we are getting currently:

I tried over and over, but it fails due to a cgroups problem.

@sergio-costas
Copy link
Copy Markdown
Contributor Author

I would still like to launch a proper dbus session, or even the whole systemd --user session where we test, so that we actually have the portals running as we are getting currently

In fact, I'm already configuring the DBUS environment variable to point to the already-running dbus-session instance, and both dconf-daemon and xdg-desktop-portal binaries are being automatically launched, so that error must be due to a different reason.

@sergio-costas
Copy link
Copy Markdown
Contributor Author

The problem with mattermost is in mattermost itself, so we have to wait for a new version.

@3v1n0
Copy link
Copy Markdown
Contributor

3v1n0 commented Apr 14, 2026

I would still like to launch a proper dbus session, or even the whole systemd --user session where we test, so that we actually have the portals running as we are getting currently

In fact, I'm already configuring the DBUS environment variable to point to the already-running dbus-session instance, and both dconf-daemon and xdg-desktop-portal binaries are being automatically launched, so that error must be due to a different reason.

Could be because the gtk portal does not implement it? Should we try the gnome one?

Comment thread .github/workflows/test_script.sh Outdated
Comment thread .github/workflows/test_script.sh
@sergio-costas
Copy link
Copy Markdown
Contributor Author

I restored all the flags.

@sergio-costas
Copy link
Copy Markdown
Contributor Author

@3v1n0 Maybe the problem with Evince is this? Apr 15 09:24:34 runnervm35a4x dbus-daemon[14816]: apparmor="DENIED" operation="dbus_method_call" bus="session" path="/org/freedesktop/portal/desktop" interface="org.freedesktop.host.portal.Registry" member="Register" mask="send" name="org.freedesktop.portal.Desktop" pid=14871 label="snap.evince.evince" peer_pid=15231 peer_label="unconfined"

This PR builds the runtime agains a new SDK, and tests it against
several snaps. Specifically, it tests:

* firefox
* thunderbird
* darktable
* cheese
* gimp
* gnome-calculator
* gnome-system-monitor
* gnome-text-editor
* evince
* kicad
* chromium
* shotwell
* telegram
* mattermost

It uses YARF OCR capabilities to detect that the application has
been launched correctly. After it detects it, it waits five
seconds and test again, to ensure that it is still working (thus
to avoid the case where the window does appear but the
application crashes immediately).

If a test fails, it uploads an artifact with the YARF logs, to
check if it's a test problem or a PR problem.
@sergio-costas
Copy link
Copy Markdown
Contributor Author

@3v1n0 Ok, I restored everything. When mattermost is fixed, I think that we can merge this.

Comment thread .github/workflows/test_script.sh Outdated
@sergio-costas
Copy link
Copy Markdown
Contributor Author

@3v1n0 Ok, all tests are passing!!!!! The only open conversation is the name for the YARF logs files.

export GNOME_SETUP_DISPLAY=:1

# use only GTK portal, since mutter isn't running
sudo sed -i -e 's/gnome;gtk;/gtk;/g' /usr/share/xdg-desktop-portal/gnome-portals.conf
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mmh, sketchy. we could avoid lying about being a GNOME desktop instead, and it should default to xdg-desktop-portal-gtk already.

On the other hand, I know for a fact that some third party applications check for XDG_CURRENT_DESKTOP=GNOME before enabling some features so maybe this more realistic than not lying about being GNOME...

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

Successfully merging this pull request may close these issues.

3 participants