'Returns an artist string (all artists) and an artist_id (the main
artist) for a list of Beatport release or track artists.'

def _get_artist(self, artists):

    artist_id = None
    bits = []
    for artist in artists:
        if (not artist_id):
            artist_id = artist[0]
        name = artist[1]
        name = re.sub('    \\(\\d+\\)$', '', name)
        name = re.sub('^(.*?),    (a|an|the)$', '\\2    \\1', name, flags=re.I)
        bits.append(name)
    artist = (',    '.join(bits).replace('    ,', ',') or None)
    return (artist, artist_id)
