Trouble with ROS and Gstreamer

Hello,

I have recently spent a large amount of time trying to build a snap which makes use of both Gstreamer and ROS.
I have successfully been able to make snaps using just basic ROS packages but have hit a wall when it comes to the integration with Gstreamer. The snap build fine however when I run it I get the following warnings before the ros-node crashes.

(gst-plugin-scanner:26405): GStreamer-WARNING **: Failed to load plugin ‘/snap/private-transpower-switchyard-robot/x1/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstfluidsynthmidi.so’: libpulsecommon-8.0.so: cannot open shared object file: No such file or directory
(gst-plugin-scanner:26405): GStreamer-WARNING **: Failed to load plugin ‘/snap/private-transpower-switchyard-robot/x1/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstpulse.so’: libpulsecommon-8.0.so: cannot open shared object file: No such file or directory
No cameras found.
(tcam_handler_node:26379): GLib-GObject-CRITICAL **: g_object_ref: assertion ‘G_IS_OBJECT (object)’ failed

When I run the ROS node normally it correctly finds the connected camera.

My current .yaml looks like:

name: tcam-test
version: 1.0
summary: tcam-test
description: Contains ROS packages and a .launch file.
confinement: devmode
grade: stable

apps:
  run:
    command: roslaunch tcam_handler tcam_handler_node.launch
  plugs:
    - raw-usb
    - serial-port
    - hidraw
    - gpio
    - i2c
    - network-bind
    - network
    - home
    - joystick
    - pulseaudio
    - camera
  environment:
    GST_PLUGIN_PATH: $SNAP/usr/lib/x86_64-linux-gnu/gstreamer-1.0
    GST_PLUGIN_SCANNER: $SNAP/usr/lib/x86_64-linux-gnu/gstreamer1.0/gstreamer-1.0/gst-plugin-scanner
    GI_TYPELIB_PATH: $SNAP/usr/lib/girepository-1.0:$SNAP/usr/lib/x86_64-linux-gnu/girepository-1.0
    LD_LIBRARY_PATH: $SNAP/usr/lib/$ARCH/pulseaudio
  
parts:
  ros-project:
    after:
      - tcamgstcamera
      - tcam
     plugin: catkin
     source: .
     rosdistro: kinetic
     build-packages:
       - libboost-dev
       - libboost-serialization-dev
       - cmake
       - libgstreamer1.0-dev
       - libgstreamer-plugins-base1.0-0
       - libgstreamer-plugins-base1.0-dev
       - libgstreamer-plugins-good1.0-0
       - libgstreamer-plugins-good1.0-dev
       - libgstreamer-plugins-bad1.0-0
       - libgstreamer-plugins-bad1.0-dev
       - libpulse0
       - libpulse-dev
       - pkg-config
       - build-essential
     stage-packages:
       - libgstreamer1.0-dev
       - libgstreamer-plugins-base1.0-0
       - libgstreamer-plugins-base1.0-dev
       - libgstreamer-plugins-good1.0-0
       - libgstreamer-plugins-good1.0-dev
       - libgstreamer-plugins-bad1.0-0
       - libgstreamer-plugins-bad1.0-dev
       - libpulse0
       - libpulse-dev
       - libgpm2
       - libgpm-dev
       - freeglut3-dev
       - freeglut3
       - gstreamer1.0-plugins-base
       - gstreamer1.0-plugins-good
       - gstreamer1.0-plugins-ugly
       - gstreamer1.0-plugins-bad
       - gstreamer1.0-pulseaudio
       - gstreamer1.0-libav
       - gstreamer1.0-libav-dbg
       - libprojectm2v5
       - projectm-data
       - gir1.2-gstreamer-1.0
       - gir1.2-gst-plugins-base-1.0
       - python-gi
       - python-gst-1.0
       - pulseaudio
     catkin-packages:
       - tcam_handler
  include-roscore: true
  prime: ['*']

tcamgstcamera:
  plugin: cmake
  source: ./common
  prime: ['*']

tcam:
  plugin: cmake
  source: ./tiscamera
  prime: ['*']

What is $ARCH? Should you be using the explicit triplet instead? This is where libpulsecommon is (/usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-8.0.so).

Hello Kyrofa,

I don’t even know what that line is doing I just found it somewhere online and just pasted it there…
Should I just replace it with your suggestion? Do I need $SNAP preceding it?

Yeah try making it: LD_LIBRARY_PATH: $SNAP/usr/lib/x86_64-linux-gnu/pulseaudio, see if that changes anything. You’re running on amd64, right?

That fixed the errors about libpulsecommon. Thank you.

The only error left is:

(tcam_handler_node:3748): GLib-GObject-CRITICAL **: g_object_ref: assertion ‘G_IS_OBJECT (object)’ failed

Here is the output of /snap/bin/snappy-debug.security scanlog.

I made the suggested changes to plug even though I don’t think the are important in devmode, however I still get the suggestion.

		INFO: following '/var/log/syslog'. If have dropped messages, use:
	INFO: $ sudo journalctl --output=short --follow --all | sudo snappy-debug.security scanlog
	kernel.printk_ratelimit = 0
	= AppArmor =
	Time: May 20 16:43:38
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/proc/8071/mounts" pid=8071 comm="python" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /proc/8071/mounts (read)
	Suggestions:
	* adjust program to not access '@{PROC}/@{pid}/mounts'
	* add one of 'mount-observe, network-control' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:38
	Log: apparmor="ALLOWED" operation="connect" profile="snap.tcam-test.run" name="/run/uuidd/request" pid=8071 comm="python" requested_mask="wr" denied_mask="wr" fsuid=0 ouid=0
	File: /run/uuidd/request (write)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'openvswitch-support' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:38
	Log: apparmor="ALLOWED" operation="file_perm" profile="snap.tcam-test.run" name="/run/uuidd/request" pid=8071 comm="python" requested_mask="w" denied_mask="w" fsuid=0 ouid=0
	File: /run/uuidd/request (write)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'openvswitch-support' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:38
	Log: apparmor="ALLOWED" operation="file_perm" profile="snap.tcam-test.run" name="/run/uuidd/request" pid=8071 comm="python" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/uuidd/request (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'openvswitch-support' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:38
	Log: apparmor="ALLOWED" operation="capable" info="optional: no audit" error=-1 profile="snap.tcam-test.run" pid=8121 comm="rosout" capability=19  capname="sys_ptrace"
	Capability: sys_ptrace
	Suggestions:
	* adjust program to not require 'CAP_SYS_PTRACE' (see 'man 7 capabilities')
	* do nothing if program otherwise works properly

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/bus/usb/devices/" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/bus/usb/devices/ (read)
	Suggestions:
	* adjust program to not access '/sys/bus/usb/devices/'
	* add one of 'camera, raw-usb' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.6" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.6 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-6.3:1.0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-6.3:1.0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-6:1.0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-6:1.0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.4" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.4 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.2" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.2 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:1" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:1 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.7" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.7 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-0:1.0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-0:1.0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.5" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.5 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:128" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:128 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.3" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.3 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:4" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:4 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:2" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:2 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/c189:3" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/c189:3 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:1-3:1.1" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:1-3:1.1 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/run/udev/data/+usb:2-0:1.0" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /run/udev/data/+usb:2-0:1.0 (read)
	Suggestions:
	* adjust program to use $SNAP_DATA
	* adjust program to use run/shm/snap.$SNAP_NAME.*
	* add 'hardware-observe' to 'plugs'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-11/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/[0-9]*-[0-9]*.[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/[0-9]*-[0-9]*.[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/[0-9]*-[0-9]*.[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-6/1-6.3/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/[0-9]*-[0-9]*/[0-9]*-[0-9]*.[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb2/busnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb2/busnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb2/busnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/busnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb2/devnum" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb2/devnum (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb2/devnum'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/devnum'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb2/speed" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb2/speed (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb2/speed'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/speed'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/sys/devices/pci0000:00/0000:00:14.0/usb2/descriptors" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /sys/devices/pci0000:00/0000:00:14.0/usb2/descriptors (read)
	Suggestions:
	* adjust program to not access '/sys/devices/pci0000:00/0000:00:14.0/usb2/descriptors'
	* adjust program to not access '/sys/devices/pci[0-9]*:[0-9]*/[0-9]*:[0-9]*:[0-9]*.[0-9]*/usb[0-9]*/descriptors'

	= AppArmor =
	Time: May 20 16:43:41
	Log: apparmor="ALLOWED" operation="open" profile="snap.tcam-test.run" name="/etc/wildmidi/wildmidi.cfg" pid=8148 comm="gst-plugin-scan" requested_mask="r" denied_mask="r" fsuid=0 ouid=0
	File: /etc/wildmidi/wildmidi.cfg (read)
	Suggestion:
	* adjust program to read necessary files from $SNAP, $SNAP_DATA, $SNAP_COMMON, $SNAP_USER_DATA or $SNAP_USER_COMMON

@mhampton You have to set the environment variables in order to let gstreamer find your plugins
Try setting the following environment variables.

GST_PLUGIN_SYSTEM_PATH: $SNAP/usr/lib/gstreamer-1.0
GST_PLUGIN_SCANNER: $SNAP/usr/libexec/gstreamer-1.0/gst-plugin-scanner 

Works for me