Audio-recorder doesn't run under Quantal Ubuntu distribution

Bug #1074928 reported by Xavier Farret
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Audio Recorder
Fix Released
Critical
moma
Arch Linux
In Progress
Undecided
moma

Bug Description

I've just upgrade audio-recorder to 0.9.7 on quantal distrib and i've got trouble to launch it :
Error: Cannot find settings for /apps/audio-recorder/ in GNOME's
registry. Please run "make install" as sudo or root user.

I try on a fresh quantal install, the trouble is the same. All installation are on 64bits.

moma (osmoma)
Changed in audio-recorder:
assignee: nobody → moma (osmoma)
importance: Undecided → Critical
moma (osmoma)
Changed in audio-recorder:
status: New → In Progress
Revision history for this message
moma (osmoma) wrote :

This bug has been fixed in version 0.9.8.
Audio-recorder failed to find configuration settings in DConf and exited (in version 0.9.7 of audio-recorder).
Some facts:
1) The /apps/audio-recorder/ schema was visible in dconf-editor.
$ dconf-editor

2) Dump of /apps/ did not returned anything for a.r when this bug was present.
$ dconf dump /apps/

3) The schema (template) was correctly installed to /usr/share/glib-2.0/schemas/
$ ls -l /usr/share/glib-2.0/schemas/*audio*
-rw-r--r-- 1 root root 4897 Nov 4 21:43 /usr/share/glib-2.0/schemas/org.gnome.audio-recorder.gschema.xml

4) Gsettings list-schemas correctly reported all keys.
$ gsettings list-schemas | grep -i audio
  org.gnome.audio-recorder
  org.gnome.audio-recorder.track
  org.gnome.audio-recorder.skype
  org.gnome.audio-recorder.players

5) The user's private values for /apps/audio-recorder/ are saved to "$HOME/.config/dconf/user" file. It's a binary file. This file had no entries for a.r because it was never started in the actual Ubuntu-machine (with this bug).
$ ls -l $HOME/.config/dconf/user

The error was located in src/dconf.c, function conf_get_base_settings() where g_settings_schema_source_lookup() failed to find config schema for /apps/audio-recorder/. This schema is configured by data/org.gnome.audio-recorder.gschema.xml that is compiled and installed to the system.

This error was fixed by calling g_settings_schema_source_lookup() and setting its last parameter to TRUE. (recursive=TRUE).
GSettingsSchema *schema = g_settings_schema_source_lookup(source, APPLICATION_SETTINGS_SCHEMA, TRUE);

Now the program correctly finds the /apps/audio-recorder/ in Gsettings (with DConf backend). User's private values (values != default) are saved to $HOME/.config/dconf/user. And all is good.

Thanks to Yéna for making several tests to fix this bug.

Changed in audio-recorder:
status: In Progress → Fix Released
Revision history for this message
mark (emailthistomark) wrote :

I am getting this same error message ("Cannot find settings for /apps/audio-recorder/ in GNOME's registry. Please run "make install" as sudo or root user.") when trying to start audio-recorder, but I used version 0.9.8 to compile the program. Also, I am not using Ubuntu, I am using Arch.

I did a bit of poking around and the schema was visible in dconf-editor. However if I run "gsettings list-schemas | grep -i audio" I get nothing back.

Here is the PKBUILD I used to create my audio-recorder package:
https://aur.archlinux.org/packages/au/audio-recorder/PKGBUILD

Revision history for this message
moma (osmoma) wrote :

Hello Mark,

1a) Please check if you find the "org.gnome.audio-recorder.gschema.xml".
$ ls -l /usr/share/glib-2.0/schemas/*audio*

I think you already have put the file in /usr/share/glib-2.0/schemas/.

1b) Then re-compile all XML schemas (do as root or sudo). Have you done this? Run:

glib-compile-schemas /usr/share/glib-2.0/schemas/
-----

2) The original code of conf_get_base_settings() in src/dconf.c was this. Can you temporarily replace the function with this code. I modified this function to be able to detect if user has compiled and installed the GSettings-schema file correctly. This older version simply seq-faults if the "settings" object is NULL. Test the code from a terminal window.

GSettings *conf_get_base_settings() {
    // Return GSettings (base) object. This points to /apps/audio-recorder/.

    GSettings *settings = g_settings_new(APPLICATION_SETTINGS_SCHEMA);

    if (!G_IS_SETTINGS(settings)) {
         LOG_ERROR("Cannot find settings for %s\n", APPLICATION_SETTINGS_SCHEMA);
         return NULL;
    }
    return settings;
}
--------

3) Does Arch-Linux use DConf as its Gsettings backend? It propably does. I am not sure how to check this.
Does Arch run GNOME or KDE?

Kindly report your findings.

moma (osmoma)
Changed in archlinux:
assignee: nobody → moma (osmoma)
assignee: moma (osmoma) → nobody
status: New → Incomplete
Revision history for this message
mark (emailthistomark) wrote :

Thanks for the help

I changed the code of "dconf.c" as you indicated in post 3 [ https://bugs.launchpad.net/audio-recorder/+bug/1074928/comments/3 ] and compiled the package again. That seems to have fixed this issue with audio-recorder failing to start.

I'll leave a note over on Arch User Repository pointing people to this thread.

BTW- Arch can be installed to run about any desktop environment, but I am using Gnome 3/Gnome-Shell

thanks again.

Revision history for this message
moma (osmoma) wrote :

Hello,
Very good Mark.
I will consider rollback to the original code (or find a better solution) so it works in all distros.

Would you please send me the Arch-spesific files for compilation and packaging so I can add then to the source-tree on Launchpad.net. My email: osmoma at gmail punto com

I will add a new directory called "Arch-Linux". Is this name OK?
http://bazaar.launchpad.net/~osmoma/audio-recorder/trunk/ <-- Arch-Linux

BTW: I am preparing a new version for Ubuntu 13.04 (april 2013). Eg. the hard-coded values in src/media-profiles.c can now be removed because GNOME-media has (propably) added new values for Gstreamer 1.0.
Ref: http://bazaar.launchpad.net/~osmoma/audio-recorder/trunk/view/head:/src/media-profiles.c

moma (osmoma)
Changed in archlinux:
assignee: nobody → moma (osmoma)
status: Incomplete → In Progress
Revision history for this message
mark (emailthistomark) wrote :

Sure.

All we really have for audio-recorder in Arch is just a simple script for building the package which I will link to below:

https://aur.archlinux.org/packages/au/audio-recorder/PKGBUILD

Here are direct links for downloading the specified dependencies from the Arch repositories:
hicolor-icon-theme https://www.archlinux.org/packages/extra/any/hicolor-icon-theme/download/
dconf https://www.archlinux.org/packages/extra/i686/dconf/download/
libgnome-media-profiles https://www.archlinux.org/packages/extra/i686/libgnome-media-profiles/download/
gstreamer0.10-good-plugins https://www.archlinux.org/packages/extra/i686/gstreamer0.10-good-plugins/download/
gstreamer0.10-ugly-plugins
gstreamer0.10-bad-plugins

Revision history for this message
mark (emailthistomark) wrote :

Missed two:

gstreamer0.10-ugly-plugins https://www.archlinux.org/packages/extra/i686/gstreamer0.10-ugly-plugins/download/
gstreamer0.10-bad-plugins https://www.archlinux.org/packages/extra/i686/gstreamer0.10-bad-plugins/download/

Let me know if that was not what you need. I would be happy to help out.

moma (osmoma)
summary: - udio-recorder doesn't run under Quantal Ubuntu distribution
+ Audio-recorder doesn't run under Quantal Ubuntu distribution
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.