We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit a1461b6b authored by clint's avatar clint

show us what's broken with mbids in the jamendo dump

parent 71c3dd63
......@@ -261,7 +261,10 @@ class JamendoImport:
artist["image"] = artist_e.text
if artist_e.tag == "mbgid":
artist["mbid"] = artist_e.text
if len(artist_e.text) == 36:
artist["mbid"] = artist_e.text
else:
print "Artist mbgid wrong length (%d): %s" % (len(artist_e.text),artist_e.text)
if artist_e.tag == "url":
artist["url"] = artist_e.text
......@@ -296,7 +299,10 @@ class JamendoImport:
album["tags"].append(genre)
if album_e.tag == "mbgid":
album["mbid"] = album_e.text
if len(album_e.text) == 36:
album["mbid"] = album_e.text
else:
print "Album mbgid wrong length (%d): %s" % (len(album_e.text),album_e.text)
if album_e.tag == "license_artwork":
album["license_artwork"] = album_e.text
......@@ -336,6 +342,12 @@ class JamendoImport:
if track_e.tag == "duration":
track["duration"] = track_e.text
if track_e.tag == "mbgid":
if len(track_e.text) == 36:
track["mbid"] = track_e.text
else:
print "Track mbgid wrong length (%d): %s" % (len(track_e.text),track_e.text)
if track_e.tag == "Tags":
for tag_e in track_e.getchildren():
track["tags"].append(self.proc_tag(tag_e))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment