Skip to content

Conversation

@mihawk90
Copy link
Contributor

@mihawk90 mihawk90 commented Jan 29, 2025

Description

This is a quick and dirty detection that assumes that if a distribution were to package their own Flatpak, they would also use their own custom built runtime (we already have one such example).

A "proper" detection would involve changing how and what OBS logs about the Flatpak environment and use that instead. Since that requires some additional considerations, that is out of scope for now. See obsproject/obs-studio#11788 for work towards that.

As discussed with tytan in #documentation on Discord, we're going with this quick detection until such time that this "proper" detection is ready.

Motivation and Context

We recently had a user in #linux-support having issues with both their BlackMagic capture card as well as their Nvidia GPU being detected. Upon inspection of the log, tytan noticed this was not our official Flatpak, and it unfortunately also happens to be broken in other ways.

How Has This Been Tested?

#!/bin/bash

echo "===== Unofficial Flatpak ====="
./loganalyzer.py --url "https://obsproject.com/logs/5PhBee18cV5S6MBe"

The second string was tested with the same log, replacing the runtime identifier.

Types of changes

  • New feature (non-breaking change which adds functionality)

Checklist:

  • My code has been run through clang-format.
  • I have read the contributing document.
  • My code is not on the master branch.
  • The code has been tested.
  • All commit messages are properly formatted and commits squashed where appropriate.
  • I have included updates to all appropriate documentation.

@mihawk90 mihawk90 force-pushed the linux-unofficial-flatpak branch from 5cbc079 to 9c6a28b Compare June 18, 2025 08:15
@mihawk90 mihawk90 force-pushed the linux-unofficial-flatpak branch 2 times, most recently from 521ddcf to e44947d Compare July 2, 2025 20:46
@mihawk90
Copy link
Contributor Author

Since obsproject/obs-studio#11788 landed we might rethink how this could be done the "proper" way.

We can already grab "valid" commit hashes fairly easily:

# same for `flathub-beta` of course
❯ flatpak remote-info flathub com.obsproject.Studio --log | grep Commit | cut -d: -f2
 4249e4245f75bbec5ad89a4bcfb2726ecbe54c7f3a642e6dbe2820ff4ac2dbc9
 caf0e8d12e2e072b8955a01815fac498746fd8da8de752f6d38a986fd5b21462
 dee53614e7db9461d9e8247db81dfdfda4cdbbdad2d329a522c3946c19cc0386
 bda2690638a8f078c50a9f525e5b8a996c9186e71af1d65ff33fa7396c8de5c3
 a57498baa7462d859465d5ddedb1918b677f4b1306c7613da73c7c49e327dd19
 dc38e67bbca5d6c9c3d005f84bbf006109310de3852a9cd32b1dc19e030b1b0c
 68d5e09141770575d2c962c06dea2bde8c8f97f035a75f6a47b0c1dfd39a7749
 bf9183bb1b4f291037a55df64402ed2dda0a8236907545c1a699ca1b205396fe
 4c452dfbd40bad7156b04449b61eb0bb651456f0848cd7e04c3064aac1ab2e90
 71d974e21fd96594d6ce66314962435a46674e1c441abcc9a6d64cbe5a5f7eda
 9acb8be364db52dcb4ea8ff0b20d63579ecd18d22bd7419deb20a2245356ffd7
 c5bc6eb99d2d638e0892320dd43d0cd5f948d6d90bf786abe2995087a068d131
 e641d66f8f509ff18c1e82bfd6e32e0e0021e56cb01d1471b00f56d82ea8bfa1

Obviously it doesn't really make sense to grab this on every log, but we could write this to a file that is updated either manually or through some CI, that is then read for Flatpak logs.
So the question would be how to do this most efficiently.

@mihawk90 mihawk90 force-pushed the linux-unofficial-flatpak branch from e44947d to aa110c6 Compare September 23, 2025 23:28
@RytoEX
Copy link
Member

RytoEX commented Oct 29, 2025

#177 was merged, so this can be rebased and undrafted. Though, #177 is triggering with Windows logs, so it may need a follow-up.

@mihawk90
Copy link
Contributor Author

mihawk90 commented Oct 29, 2025

If we still want the "simple" check I can do that, just wanted to make sure we didn't wanna do the "proper" check instead right away.

This check is isolated to isFlatpak(), so the fix for #177 (i.e. either #193 or #194) shouldn't make a difference.

@mihawk90 mihawk90 force-pushed the linux-unofficial-flatpak branch from aa110c6 to 7c0194f Compare October 29, 2025 12:58
@mihawk90 mihawk90 marked this pull request as ready for review October 29, 2025 13:00
This is a quick and dirty detection that assumes that if a distribution
were to package their own Flatpak, they would also use their own custom
built runtime (we already have one such example).

A "proper" detection would involve changing how and what OBS logs about
the Flatpak environment and use that instead. Since that requires some
additional considerations, that is out of scope for now.
@mihawk90 mihawk90 force-pushed the linux-unofficial-flatpak branch from 7c0194f to f8f2887 Compare October 29, 2025 20:57
@RytoEX RytoEX requested a review from Fenrirthviti November 5, 2025 22:00
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.

2 participants