Gstreamer audio problem - no service found for - "org.qt-project.qt.mediaplayer'


I am new to snaps.

I have been snapping the open source brewing software ‘Brewtarget’. With the help of McPhail I have got it mostly up and running. The exception is with countdown timers [like cooking timers] - when they reach 0 and set off the alarm you it doesn’t produce any sound.

Attempts to find the missing libraries

If I run the snap and trigger an alarm I get the following terminal output

defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer

If I run the deb version with


and trigger the alarm I see text including:

Got keys from plugin meta data ("gstreamercamerabin")
Got keys from plugin meta data ("gstreamermediacapture")
Got keys from plugin meta data ("gstreamermediaplayer") 

So fine, I figure the issue is gstreamer and mediaplayer related. I looked at other snaps and copied relevant parts of their yaml but so far to no avail.

I ran ‘ldd’ on the deb and made sure that I had the mentioned libraries in my stage-packages.

But it still doesn’t work.

:confused: Stuck, please send help! :sos:

I am stuck on how to proceed from here, and would appreciate any advice. Am I even correct in thinking that this is a library issue - or should I be looking at env, paths etc?

My snapcraft.yaml now:

name: padraic-brewtarget # you probably want to 'snapcraft register <name>'
base: core18 # the base snap is the execution environment for this snap
version: '2.4.0-develop' # just for humans, typically '1.2+git' or '1.3.2'
summary: Brewtarget is brewing software, FREE as in Libre & Beer. Perfect for homebrew! # 79 char long summary
description: |
    Brewtarget is FREE brewing software, and an open source beer recipe creation tool. It automatically calculates color, bitterness, and more for you while you drag and drop ingredients into the recipe. Brewtarget also has many other tools such as priming sugar calculators, OG correction help, and a unique mash designing tool. It can export and import recipes, allowing you to easily share them with friends. All of this means that Brewtarget is your single, free, go-to tool when crafting your beer recipes.
grade: devel # must be 'stable' to release into candidate/stable channels
confinement: strict # use 'strict' once you have the right plugs and slots

    command: $SNAP/bin/brewtarget
     - bin/session-manager-workaround
      - kde-neon
      - home
      - audio-playback
      - desktop
      - desktop-legacy
      - wayland
      - x11
      - unity7
      - opengl
      - alsa
      - pulseaudio
      - jack1

# The session-manager-workaround launcher: Silent error messages due to inaccessible paths
    source-tag: v1.0.0
    plugin: dump
      - bin/*
    # See 'snapcraft plugins'
    source: .
  #source-branch: devel
    plugin: cmake
    build-packages: [g++, cmake, git, qtbase5-dev, qttools5-dev, qttools5-dev-tools, qtmultimedia5-dev, libqt5sql5-sqlite, libqt5sql5-psql, libqt5svg5-dev, libqt5multimedia5-plugins, doxygen]

      - libasyncns0
      - libdouble-conversion1
      - libflac8
      - libfreetype6
      - libgl1
      - libglvnd0
      - libglx0
      - libgraphite2-3
      - libharfbuzz0b
      - libicu60
      - liblz1
      - liblzma5
      - libogg0
      - libpcre3
      - libpng16-16
      - libpulse0
      - libqt5core5a
      - libqt5gui5
      - libqt5multimedia5
      - libqt5network5
      - libqt5printsupport5
      - libqt5sql5
      - libqt5sql5-sqlite
      - libqt5svg5
      - libqt5widgets5
      - libqt5xml5
      - libsndfile1
      - libsqlite3-0
      - libstdc++6
      - libsystemd0
      - libvorbis0a
      - libvorbisenc2
      - libwrap0
      - libx11-6
      - libxau6
      - libxcb1
      - libxdmcp6
      - libz1
      - sqlitebrowser
        #gstreamer packages from here
      - libgstreamer1.0-0
      - gstreamer1.0-pulseaudio
      - gstreamer1.0-plugins-base
      - gstreamer1.0-plugins-good
      - gstreamer1.0-plugins-bad
      - libpulse-mainloop-glib0
      - libasound2
      - libslang2
      - libgpm2
      - libgirepository-1.0-1
      - gir1.2-gstreamer-1.0

    symlink: $SNAP/usr/share/brewtarget
    symlink: $SNAP/usr/share/doc/brewtarget

Hi Padraic.

Did you manage to solve that “no service found” problem?

I have the same issue and I can’t play videos using QMediaPlayer.

No, I’m afraid I never did.

I had the same problem. After adding the following it was fixed:

  • installed gstreamer
  • installed qt6-multimedia-dev
  • added $SNAP/lib/python3.10/site-packages/PyQt6/Qt6/lib to the PYTHONPATH and LD_LIBRARY_PATH
  • set environemental var QT_MEDIA_BACKEND=gstreamer

Not all of these steps might have been needed, but this setup works buzz/snap/snapcraft.yaml at fix-snap-audio · chidiwilliams/buzz · GitHub

If someone can rule out extra / unneeded steps, a comment here would be appreciated.