[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gap-dev-discuss] Cynthiune -- MusicBrainz support

From: Sebastian Reitenbach
Subject: Re: [Gap-dev-discuss] Cynthiune -- MusicBrainz support
Date: Sat, 09 Jun 2012 11:34:07 +0200

Hi Yavor,

Yavor Doganov <address@hidden> wrote: 
> Please find the patch attached.  I'm not happy with it, but I guess
> it's better to submit it as it is for discussion.

Thanks for the patch. I just tested on OpenBSD i386 against
libmusicbrainz-3.0.2. It compiles and works just fine.

> Caveats:
>   * MusicBrainz support is demoted to optional (detected
>     automatically).  I think this is good, as it not essential
>     functionality for a music player.
>   * The test to detect the libmusicbrainz version is very weak, but I
>     guess that's as best as we can do without resorting to Autoconf.
>     It should work in most cases.

I'd put a 
ifneq ($(disable-musicbrainz), yes)
around the stuff added to the GNUmakefile.preamble. Just in case someone has
musicbrainz installed, but doesn't want to link against it.

>   * I get occasional crashes that are extremely hard to debug and end
>     up often in GNUstep Back and glibc's low level memory allocation
>     routines.  I tested only on Debian GNU/Linux with a fairly old
>     GNUstep installation (GUI 0.18.0), so it might be that some GUI
>     classes are not entirely thread-safe, or an NSLock is needed
>     somewhere.
>   * With libmusicbrainz3, the album title always coincides with the
>     song title, which is utterly wrong.  There's no equivalent C
>     function to obtain the release from the track so I don't have any
>     clues how to fix this.  mb_track_get_id and mb_release_get_id
>     return the same string, so quite clearly something is not right.
>   * I couldn't find a way to extract the release year with
>     libmusicbrainz3; most probably this is related with the problem
>     above.
>   * No track number extraction with both versions of the library.

At least, when I look at the console, I can see the following when retrieving
info about a Song, for example:

MusicBrainz: Connecting to
MusicBrainz: GET /ws/1/track/?type=xml&title=Ghost&artist=Unsane
MusicBrainz: Result: 0 (200 OK)
MusicBrainz: Status: 200
MusicBrainz: Response:
<?xml version="1.0" standalone="yes"?><metadata
xmlns:ext="";><track-list offset="0"
count="1"><track id="d392ad45-e2a6-46ee-a126-7b242f7d6b4e" ext:score="100"
offset="5" count="10"/></release></release-list></track></track-list></metadata>

So the title and the album name are given back from the server correctly. Also
the track number too. The offset="5" count="10" seems to mean: track 6 from 10
tracks. The offset seems to start counting with 0.
The year doesn't seem to be returned from the server.

I did not yet looked much at the code, but I'll install other apps that work
with MusicBrainz, and will look into their code, what they are doing.

Another glitch I recognized: When for example a song has the year set in its
tags, and I update the info from MusicBrainz, then the info in the year field
vanishes. I think for The MB button should only update fields, where it got
values back. If it didn't got info about the year, it should not update the


> Comments welcome.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]